Amazon Lightsail に SSL 証明書設置 with Let's Encrypt (自動更新)
Amazon Lightsail に SSL 証明書設置 with Let's Encrypt (自動更新)
Let's Encrypt による SSL 証明書の導入
$ sudo apt-get update
$ sudo apt-get install software-properties-common
$ sudo apt-add-repository ppa:certbot/certbot -y
$ sudo apt-get update -y
$ sudo apt-get install certbot -y
$ wget https://github.com/joohoi/acme-dns-certbot-joohoi/raw/master/acme-dns-auth.py
$ chmod +x acme-dns-auth.py
$ vi acme-dns-auth.py
$ sudo mv acme-dns-auth.py /etc/letsencrypt/
$ sudo certbot certonly --manual --manual-auth-hook /etc/letsencrypt/acme-dns-auth.py --preferred-challenges dn
s --debug-challenges -d hayashier.com
$ sudo cp /etc/letsencrypt/live/hayashier.com/fullchain.pem /opt/bitnami/apache2/conf/server.crt
$ sudo cp /etc/letsencrypt/live/hayashier.com/privkey.pem /opt/bitnami/apache2/conf/server.key
$ sudo /opt/bitnami/ctlscript.sh restart apacheSSL 証明書の自動更新設定
以前の方法
SSL 証明書の自動更新設定
動作確認
httpsへ強制
数ヶ月に1回程度落ちる
PreviousElastic Beanstalkでインスタンス入れ替え後にnginxのデフォルトの画面が表示されてしまう問題の対応NextAmazon Lightsailで10分で作るお手軽Markdownで書く独自ドメインのブログサイト構築
Last updated