本日、スタートアップスクリプト「Mastodon」を更新致しました。
変更内容は以下の通りです。
- 証明書自動更新コマンドのコマンドオプション修正
また、本日(2017/7/10)12:00以前にスタートアップスクリプトでMastodonインスタンスを作成された方は、SSL証明書が自動的に更新されない不具合が発生するため、さくらのクラウドのコンソールやSSHクライアントから、rootユーザで以下コマンドの実行をお願い致します。なお、証明書更新処理中に Webサービスの停止が数秒間発生致します。
※コマンドプロンプト(“#”)1つにつき1行のコマンドとして入力してください
・証明書の手動更新(証明書を手動で更新します。nginxの停止/起動が行われます)
# /usr/local/certbot/certbot-auto renew --standalone --pre-hook 'systemctl stop nginx' --post-hook 'systemctl start nginx' --force-renew
・cronの設定変更
# echo "$((${RANDOM}%60)) $((${RANDOM}%24)) * * $((${RANDOM}%7)) root /usr/local/certbot/certbot-auto renew --standalone --preferred-challenges tls-sni-01 --pre-hook 'systemctl stop nginx' --post-hook 'systemctl start nginx'" > /etc/cron.d/certbot-auto
・証明書の取得日/期限日の確認
# DOMAIN=example.com # openssl s_client -connect ${DOMAIN}:443 < /dev/null 2> /dev/null | openssl x509 -text | grep "Not " Not Before: Jul 4 13:10:00 2017 GMT Not After : Oct 2 13:10:00 2017 GMT
※1行目のコマンドラインの「example.com」はお客様ドメインに置き換えてください