自宅で使っているサーバをSSL化するにcertbotをインストールしてコマンド入れても
Challenge failed for domain plusload.net
になって失敗するので手動で証明書を作成してみる
root@ubuntu:~/certbot# ./certbot-auto certonly --manual Saving debug log to /var/log/letsencrypt/letsencrypt.log Plugins selected: Authenticator manual, Installer None Please enter in your domain name(s) (comma and/or space separated) (Enter 'c' to cancel): plusload.net Obtaining a new certificate An unexpected error occurred: There were too many requests of a given type :: Error creating new order :: too many failed authorizations recently: see https://letsencrypt.org/docs/rate-limits/ Please see the logfiles in /var/log/letsencrypt for more details.
わっ。失敗MAXだった。明日やってみる事にする。で、翌日。
まず、ターミナルを2つ起動し、一つ目で認証に使う認証ファイルを作り、カレントにファイルで格納する。
root@ubuntu:~/certbot# ./certbot-auto certonly --manual Saving debug log to /var/log/letsencrypt/letsencrypt.log Plugins selected: Authenticator manual, Installer None Please enter in your domain name(s) (comma and/or space separated) (Enter 'c' to cancel): plusload.net Obtaining a new certificate Performing the following challenges: http-01 challenge for plusload.net - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - NOTE: The IP of this machine will be publicly logged as having requested this certificate. If you're running certbot in manual mode on a machine that is not your server, please ensure you're okay with that. Are you OK with your IP being logged? - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - (Y)es/(N)o: y - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Create a file containing just this data: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx And make it available on your web server at this URL:http://plusload.net/.well-known/acme-challenge/zzzzzzzzzzzzzzzzzzzzzzzzzzzz - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Press Enter to Continue
とここまででいったん終わり。で次のターミナルでメッセージのようにディレクトリを作成し指定の名前で認証情報を入れます。
注意!:認証情報とファイル名は違います。指定の名前にしないと読めませんので注意しましょう。
カレントが/var/www/html/ならば以下のようにします。
root@ubuntu:~# mkdir -p /var/www/html/.well-known/acme-challenge/ root@ubuntu:~# cd /var/www/html/.well-known/acme-challenge/ root@ubuntu:/var/www/html/.well-known/acme-challenge# echo "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" > zzzzzzzzzzzzzzzzzzzzzzzzzzzz
で作成したディレクトリ内に指定の名前のファイルがあればOKです。
これで最初のターミナルへ戻ります。
Press Enter to Continue Waiting for verification... Cleaning up challenges Subscribe to the EFF mailing list (email: xxxx@gmail.com). IMPORTANT NOTES: - Congratulations! Your certificate and chain have been saved at: /etc/letsencrypt/live/plusload.net/fullchain.pem Your key file has been saved at: /etc/letsencrypt/live/plusload.net/privkey.pem Your cert will expire on 2020-12-18. To obtain a new or tweaked version of this certificate in the future, simply run certbot-auto again. To non-interactively renew *all* of your certificates, run "certbot-auto renew" - If you like Certbot, please consider supporting our work by: Donating to ISRG / Let's Encrypt: https://letsencrypt.org/donate Donating to EFF: https://eff.org/donate-le
こうなれば成功です。nginxの場合は設定ファイルのSSLのコメントアウトを削除して認証ファイル、キーファイルを設定しましょう。
簡単なので是非この機会にSSL化してください。証明書が無料なんていい時代ですね。