找回密碼
 立即註冊
搜索
熱搜: 活動 交友 discuz
查看: 214|回復: 0

SSL let's encrypt申請教學成功 SSL 更新 重申請

[複製鏈接]

301

主題

10

回帖

1310

積分

金牌會員

積分
1310
發表於 2023-12-4 09:27:11 | 顯示全部樓層 |閱讀模式
------------------------------------------------------------------------------SSL let's encrypt申請教學成功經驗------------------------------------------------------------

成功SSL let's encrypt申請教學

參考網站1:https://blog.miniasp.com/post/20 ... ypt-using-Certbot-2
參考網站2:https://www.myfreax.com/secure-n ... ncrypt-on-centos-8/

安裝套件
dnf install certbot

申請指令
certbot certonly

2: Place files in webroot directory (webroot)    -------------------------因為是apache 另一個是nginx的選項

Enter email address (used for urgent renewal and security notices) (Enter 'c' to cancel): xxx@gmail.com

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Please read the Terms of Service at
https://letsencrypt.org/document ... tember-21-2022.pdf. You must
agree in order to register with the ACME server. Do you agree?
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(Y)es/(N)o: y

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Would you be willing, once your first certificate is successfully issued, to
share your email address with the Electronic Frontier Foundation, a founding
partner of the Let's Encrypt project and the non-profit organization that
develops Certbot? We'd like to send you email about our work encrypting the web,
EFF news, campaigns, and ways to support digital freedom.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(Y)es/(N)o: y
Account registered.
Please enter the domain name(s) you would like on your certificate (comma and/or space separated) (Enter 'c' to cancel): xxx.com.tw


Input the webroot for xxx.com.tw: (Enter 'c' to cancel): /var/www/html

Successfully received certificate.
Certificate is saved at: /etc/letsencrypt/live/xxx.com.tw/fullchain.pem
Key is saved at:         /etc/letsencrypt/live/xxx.com.tw/privkey.pem
This certificate expires on 2023-12-01.
These files will be updated when the certificate renews.
Certbot has set up a scheduled task to automatically renew this certificate in the background.

以上完成申請SSL

接著進入編輯黨修改建立完成文件指定位置
vi +/SSLCertificateFile /etc/httpd/conf.d/ssl.conf

以下為修改的程式碼位置
SSLCertificateFile      /etc/letsencrypt/live/www.your-domain.com.tw/cert.pem
SSLCertificateKeyFile   /etc/letsencrypt/live/www.your-domain.com.tw/privkey.pem
SSLCertificateChainFile /etc/letsencrypt/live/www.your-domain.com.tw/chain.pem

接著重啟服務(可以沒事有修改東西就重啟)
systemctl restart httpd
777
您需要登錄後才可以回帖 登錄 | 立即註冊

本版積分規則

Archiver|手機版|小黑屋|沈長緣

GMT+8, 2024-11-1 06:53 , Processed in 0.024720 second(s), 19 queries .

Powered by shen - ♪♫*•♪!

© 2023- shen! ♪♫*•♪!.

快速回復 返回頂部 返回列表