- 現在との差分 を表示
- ソース を表示
- Let's Encrypt へ行く。
3: 2022-02-18 (金) 09:42:09 iseki | 4: 2022-03-07 (月) 15:01:29 iseki | ||
---|---|---|---|
Line 38: | Line 38: | ||
*** cron [#o6968d67] | *** cron [#o6968d67] | ||
+ | **** 失敗 [#ybbf8460] | ||
- %%月一または週一%% 毎日で以下の cronを流す. | - %%月一または週一%% 毎日で以下の cronを流す. | ||
- | 00 3 1 * * /usr/bin/certbot renew 1>/dev/null 2>&1 && /etc/init.d/httpd restart 1>/dev/null 2>&1 | + | -- %%00 3 1 * * /usr/bin/certbot renew 1>/dev/null 2>&1 && /etc/init.d/httpd restart 1>/dev/null 2>&1%% |
+ | -- これだと 更新が無い場合も httpd が再起動する. | ||
+ | #br | ||
+ | |||
+ | **** 正解は以下 [#l9205dc3] | ||
+ | - cron | ||
+ | 05 4 * * * /usr/bin/certbot renew --post-hook "touch /tmp/certs_changed" 1>/dev/null 2>&1 && /usr/local/bin/restart-network-service 1>/dev/null 2>&1 | ||
+ | - /usr/local/bin/restart-network-service | ||
+ | #!/bin/bash | ||
+ | # | ||
+ | if [ ! -f /tmp/certs_changed ]; then | ||
+ | exit 1 | ||
+ | fi | ||
+ | rm /tmp/certs_changed | ||
+ | # | ||
+ | #systemctl restart cockpit | ||
+ | # | ||
+ | systemctl restart ltictr_proxy | ||
+ | sleep 1 | ||
+ | systemctl restart jupyterhub | ||
+ | # | ||
#br | #br | ||
- Let's Encrypt のバックアップ一覧
- Let's Encrypt のバックアップ差分(No. All)