Wrapper for `step ca renew` that behaves sanely with systemd

未关闭
#1,549 7 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
5/5
预计耗时
一周以上
新手友好度
20/100
Issue 类型
功能
描述清晰度
需要澄清
活跃度
停滞
领域
devops, security

调研方向

Start by reviewing the linked external wrapper repository and the behavior of step ca renew described in this issue. The issue does not name files or tests in smallstep/cli; done would require a clearly scoped decision about whether and how this systemd-oriented wrapper belongs in the CLI.

由索引模型根据 Issue 内容生成。

描述

Hi folks,

I ran into a small but persistent operational annoyance with step ca renew:

When a certificate does not need renewal, step exits with code 1.
That is technically correct – but in a systemd world, it looks like a failure.

So I wrote a tiny wrapper that makes renewal boring again:

  • Pre-checks whether renewal is actually needed
  • Only runs step ca renew when required
  • Normalizes exit codes so “nothing to do” = success
  • Supports post-renew hooks (reload nginx, haproxy, etc.)
  • Plays nicely with systemd timers and services

Repo:
https://github.com/Torstein-Eide/Step-certificate-renewal-wrapper-script

The goal is not to replace step, but to make it operationally smoother in real systems where exit codes matter and automation should stay quiet unless something actually broke.

Bluntly:
step is correct.
systemd is strict.
This script keeps the peace between them.

Feedback welcome. If this solves a problem for others, even better.

主要语言
Go
星标
4.3k
派生
320
平均合并
2 天 3 小时
30 天内合并 PR
11

环境准备

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

smallstep/cli 的其他 Issue

查看 smallstep/cli 的全部 Issue

相似的 Issue

更多 Go Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。