{"id":2003,"date":"2018-02-27T19:00:45","date_gmt":"2018-02-27T11:00:45","guid":{"rendered":"https:\/\/cloudbool.com\/archive\/?p=240"},"modified":"2018-02-27T19:00:45","modified_gmt":"2018-02-27T11:00:45","slug":"use-certbot-issue-lets-encrypt-ssl-certificate-vultr-bandwagonhost","status":"publish","type":"post","link":"https:\/\/cloudbool.com\/archive\/use-certbot-issue-lets-encrypt-ssl-certificate-vultr-bandwagonhost.html","title":{"rendered":"\u5229\u7528Certbot\u7533\u8bf7Let&#8217;s Encrypt SSL\u8bc1\u4e66"},"content":{"rendered":"<p>Let&#8217;s Encrypt\u7684\u8bc1\u4e66\u81ea\u7136\u4e0d\u7528\u591a\u8bf4\uff0c\u5927\u5bb6\u90fd\u77e5\u9053\u662f\u4e00\u4e2a\u514d\u8d39\u7684SSL\u8bc1\u4e66\uff0c\u5bf9\u4e8e\u4e2a\u4eba\u53ca\u5c0f\u4f01\u4e1a\u6765\u8bf4\uff0cLet&#8217;s Encrypt\u5bb6\u7684\u8bc1\u4e66\u7edd\u5bf9\u662f\u591f\u7528\u4e86\u3002<br \/>\n\u867d\u7136Let&#8217;s Encrypt\u5bb6\u7684\u8bc1\u4e66\u662f\u4e2a\u597d\u4e1c\u897f\uff0c\u4f46\u662f\u7533\u8bf7\u7684\u65b9\u5f0f\u5374\u5343\u5dee\u4e07\u522b\uff0c\u6211\u8fd9\u91cc\u63d0\u4f9b\u4e00\u79cd\u5dee\u5f02\u5316\u7684\u7533\u8bf7\u65b9\u5f0f\uff0c\u5728Debian\u3001CentOS\u3001Ubuntu\u7cfb\u7edf\u4e0a\u80fd\u505a\u5230\u65e0\u5dee\u5f02\u7684\u8fdb\u884c\u90e8\u7f72Let&#8217;s Encrypt\u5bb6\u7684SSL\u8bc1\u4e66\u3002<br \/>\n<!--more--><\/p>\n<h2>\u4e0b\u8f7d\u53ca\u7ed9certbot\u8d4b\u4e88\u53ef\u6267\u884c\u6743\u9650<\/h2>\n<p>\u9996\u5148\uff0c\u9009\u62e9\u9700\u8981\u4fdd\u5b58certbot\u6587\u4ef6\u7684\u76ee\u5f55\uff0c\u53ef\u4ee5\u81ea\u5b9a\u4e49\uff0c\u4e5f\u53ef\u4ee5\u9009\u62e9\u73b0\u6709\u76ee\u5f55\uff0c\u6211\u662f\u9009\u62e9\u73b0\u6709\u7684\u7cfb\u7edf\u76ee\u5f55\uff0c\u8def\u5f84\u662f<strong><em>\/usr\/local\/src<\/em><\/strong>\uff0c\u5148\u8fdb\u5165\u4fdd\u5b58\u76ee\u5f55\uff1a<\/p>\n<blockquote><p>\n  cd \/usr\/local\/src\n<\/p><\/blockquote>\n<p>\u7528wget\u547d\u4ee4\u4e0b\u8f7dcertbot\uff1a<\/p>\n<blockquote><p>\n  wget https:\/\/dl.eff.org\/certbot-auto\n<\/p><\/blockquote>\n<p>\u518d\u8d4b\u4e88\u53ef\u6267\u884c\u6743\u9650\uff1a<\/p>\n<blockquote><p>\n  chmod +x certbot-auto\n<\/p><\/blockquote>\n<p>\u5230\u8fd9\u91cc\uff0ccertbot\u7a0b\u5e8f\u5c31\u7b97\u5b89\u88c5\u597d\u4e86\uff0c\u6211\u4eec\u63a5\u4e0b\u6765\u5c31\u53ef\u4ee5\u4f7f\u7528certbot\u7a0b\u5e8f\u8fdb\u884c\u8bc1\u4e66\u7533\u8bf7\u4e86\u3002<\/p>\n<h2>\u5229\u7528certbot\u7533\u8bf7Let&#8217;s Encrypt\u8bc1\u4e66<\/h2>\n<p>\u5229\u7528certbot\u7533\u8bf7Let&#8217;s Encrypt\u8bc1\u4e66\u9700\u8981\u5982\u4e0b\u51e0\u4e2a\u6761\u4ef6\uff1a<br \/>\n&#8211; \u7cfb\u7edf\u7684root\u6743\u9650<br \/>\n&#8211; 443\u7aef\u53e3\u672a\u88ab\u5360\u7528\uff0c\u9632\u706b\u5899\u653e\u884c443\u7aef\u53e3\uff0c\u4e14\u5916\u7f51\u80fd\u76f4\u63a5\u8bbf\u95ee\u672c\u673a\u7684443\u7aef\u53e3<br \/>\n&#8211; \u57df\u540d\u89e3\u6790\u5230\u4e86\u5f53\u524d\u4e3b\u673a<br \/>\n\u6ee1\u8db3\u4ee5\u4e0a\u6761\u4ef6\u4e4b\u540e\uff0c\u6211\u4eec\u5c31\u80fd\u5f00\u59cb\u8fdb\u884cLet&#8217;s Encrypt\u8bc1\u4e66\u7684\u7533\u8bf7\u4e86\u3002<br \/>\n\u6267\u884c\u5982\u4e0b\u547d\u4ee4\uff0c\u6211\u4eec\u53ef\u5728\u4ea4\u4e92\u7a0b\u5e8f\u4e2d\u8fdb\u884c\u7533\u8bf7SSL\u8bc1\u4e66\uff1a<\/p>\n<blockquote><p>\n  .\/certbot-auto certonly\n<\/p><\/blockquote>\n<p>\u7b2c\u4e00\u6b21\u6267\u884c\u7684\u65f6\u5019\uff0c\u53ef\u80fd\u4f1a\u8fdb\u884c\u4e00\u4e9b\u521d\u59cb\u5316\u3001\u5b89\u88c5\u6240\u5fc5\u987b\u7684\u4f9d\u8d56\u7b49\u64cd\u4f5c\uff0c\u671f\u95f4\u53ef\u80fd\u9700\u8981\u624b\u52a8\u786e\u8ba4\uff0c\u5f85\u5b89\u88c5\u5b8c\u6210\u4e4b\u540e\uff0c\u4f1a\u8981\u6c42\u8f93\u5165\u4e00\u4e9b\u6240\u9700\u8981\u7684\u4fe1\u606f\uff0c\u6b65\u9aa4\u5982\u4e0b\uff1a<\/p>\n<pre><code>root@BWH123:\/usr\/local\/src# .\/certbot-auto certonly\nBootstrapping dependencies for Debian-based OSes... (you can skip this with --no-bootstrap)\n... #\u7565\u8fc7\u5176\u4e2d\u4e00\u4e9b\u7cfb\u7edf\u4f9d\u8d56\u5b89\u88c5\u6b65\u9aa4\nHow would you like to authenticate with the ACME CA?\n-------------------------------------------------------------------------------\n1: Spin up a temporary webserver (standalone)\n2: Place files in webroot directory (webroot)\n-------------------------------------------------------------------------------\nSelect the appropriate number [1-2] then [enter] (press 'c' to cancel): 1 #\u9009\u62e9\u8ba4\u8bc1\u65b9\u5f0f\uff0c\u5efa\u8bae\u9009\u62e91\nPlugins selected: Authenticator standalone, Installer None\nEnter email address (used for urgent renewal and security notices) (Enter 'c' to\ncancel): bwh321@live.com #\u8f93\u5165\u60f3\u4f7f\u7528\u7684\u90ae\u7bb1\uff0c\u7528\u4e8e\u63a5\u6536\u8bc1\u4e66\u5230\u671f\u63d0\u9192\u7b49\u4fe1\u606f\uff0c\u5efa\u8bae\u9009\u62e9\u5e38\u7528\u7684\n-------------------------------------------------------------------------------\nPlease read the Terms of Service at\nhttps:\/\/letsencrypt.org\/documents\/LE-SA-v1.2-November-15-2017.pdf. You must\nagree in order to register with the ACME server at\nhttps:\/\/acme-v01.api.letsencrypt.org\/directory\n-------------------------------------------------------------------------------\n(A)gree\/(C)ancel: A  # \u540c\u610fTOS\uff0c\u8f93\u5165A\n-------------------------------------------------------------------------------\nWould you be willing to share your email address with the Electronic Frontier\nFoundation, a founding partner of the Let's Encrypt project and the non-profit\norganization that develops Certbot? We'd like to send you email about EFF and\nour work to encrypt the web, protect its users and defend digital rights.\n-------------------------------------------------------------------------------\n(Y)es\/(N)o: N  # \u662f\u5426\u613f\u610f\u5171\u4eab\u90ae\u7bb1\u7ed9EFF\uff0c\u6211\u9009\u62e9\u4e86N\nPlease enter in your domain name(s) (comma and\/or space separated)  (Enter 'c'\nto cancel): ssl.bwh123.com  #\u8f93\u5165\u9700\u8981\u7533\u8bf7\u7684\u57df\u540d\nObtaining a new certificate\nPerforming the following challenges:\nhttp-01 challenge for ssl.bwh123.com\nWaiting for verification...\nCleaning up challenges\nIMPORTANT NOTES:\n - Congratulations! Your certificate and chain have been saved at:\n   \/etc\/letsencrypt\/live\/ssl.bwh123.com\/fullchain.pem\n   Your key file has been saved at:\n   \/etc\/letsencrypt\/live\/ssl.bwh123.com\/privkey.pem\n   Your cert will expire on 2018-05-28. To obtain a new or tweaked\n   version of this certificate in the future, simply run certbot-auto\n   again. To non-interactively renew *all* of your certificates, run\n   \"certbot-auto renew\"\n - Your account credentials have been saved in your Certbot\n   configuration directory at \/etc\/letsencrypt. You should make a\n   secure backup of this folder now. This configuration directory will\n   also contain certificates and private keys obtained by Certbot so\n   making regular backups of this folder is ideal.\n - If you like Certbot, please consider supporting our work by:\n   Donating to ISRG \/ Let's Encrypt:   https:\/\/letsencrypt.org\/donate\n   Donating to EFF:                    https:\/\/eff.org\/donate-le\nroot@BWH123:\/usr\/local\/src#\n<\/code><\/pre>\n<p>\u53ef\u4ee5\u770b\u5230\uff0c\u6309\u7167\u8981\u6c42\u8f93\u5165\u4e4b\u540e\uff0c\u6211\u4eec\u6210\u529f\u7533\u8bf7\u4e86Let&#8217;s Encrypt\u7684\u8bc1\u4e66\uff0c\u5176\u4e2d\u8bc1\u4e66\u8def\u5f84\u5728<strong><em>\/etc\/letsencrypt\/live\/ssl.bwh123.com<\/em><\/strong>\uff0c\u9700\u8981\u642d\u914dNginx\u6216\u8005Apache\u4f7f\u7528\u7684\u8bdd\uff0c\u76f4\u63a5\u4f7f\u7528\u5c31\u597d\u4e86\u3002<br \/>\n\u8bc1\u4e66\u5feb\u5230\u6709\u6548\u671f\u7ed3\u675f\u65f6\uff0c\u6211\u4eec\u540c\u6837\u4e5f\u53ef\u4ee5\u4f7f\u7528\u8fd9\u4e2a\u5c0f\u7a0b\u5e8f\u6765\u8fdb\u884c\u8bc1\u4e66\u6709\u6d88\u606f\u66f4\u65b0\uff0c\u66f4\u65b0\u547d\u4ee4\u4e3a\uff1a<\/p>\n<blockquote><p>\n  .\/certbot-auto renew\n<\/p><\/blockquote>\n<p>\u67e5\u770b\u5e2e\u52a9\u4fe1\u606f\u53ef\u4ee5\u4f7f\u7528\u5982\u4e0b\u547d\u4ee4\uff1a<\/p>\n<blockquote><p>\n  .\/certbot-auto &#8211;help\n<\/p><\/blockquote>\n<p>\u672c\u547d\u4ee4\u5728<a href=\"https:\/\/cloudbool.com\/archive\/go\/vultr\">Vultr<\/a>\u53ca<a href=\"https:\/\/cloudbool.com\/archive\/go\/bandwagonhost\">BandwagonHost<\/a>\u53ca<a href=\"https:\/\/cloudbool.com\/archive\/go\/digitalocean\">DigitalOcean<\/a>\u53ca<a href=\"https:\/\/cloudbool.com\/archive\/go\/linode\">Linode<\/a>\u4e0a\u7684VPS\u6d4b\u8bd5\u901a\u8fc7\uff0c\u642d\u914dNginx\u4e4b\u540e\u53ef\u4ee5\u6b63\u5e38\u4f7f\u7528\uff0c\u81f3\u4e8eSSL\u8bc1\u4e66\u7684\u60c5\u51b5\uff0c\u53ef\u4ee5\u67e5\u770b\u672c\u7ad9\u7684SSL\u8bc1\u4e66\uff0c\u7528\u7684\u5c31\u662fLet&#8217;s Encrypt\u7684\u8bc1\u4e66\u3002<br \/>\n\u53c2\u8003\u4fe1\u606f\uff1ahttps:\/\/certbot.eff.org\/#pip-other<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Let&#8217;s Encrypt\u7684\u8bc1\u4e66\u81ea\u7136\u4e0d\u7528\u591a\u8bf4\uff0c\u5927\u5bb6\u90fd\u77e5\u9053\u662f\u4e00\u4e2a\u514d\u8d39\u7684SSL\u8bc1\u4e66\uff0c\u5bf9\u4e8e\u4e2a\u4eba\u53ca\u5c0f\u4f01\u4e1a\u6765 &hellip;<\/p>\n<p class=\"read-more\"> <a class=\"\" href=\"https:\/\/cloudbool.com\/archive\/use-certbot-issue-lets-encrypt-ssl-certificate-vultr-bandwagonhost.html\"> <span class=\"screen-reader-text\">\u5229\u7528Certbot\u7533\u8bf7Let&#8217;s Encrypt SSL\u8bc1\u4e66<\/span> \u67e5\u770b\u5168\u6587 &raquo;<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-gradient":""}},"footnotes":""},"categories":[182],"tags":[201,100],"class_list":["post-2003","post","type-post","status-publish","format-standard","hentry","category-linux","tag-lets-encrypt","tag-ssl"],"_links":{"self":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts\/2003","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/comments?post=2003"}],"version-history":[{"count":0,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/posts\/2003\/revisions"}],"wp:attachment":[{"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/media?parent=2003"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/categories?post=2003"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cloudbool.com\/archive\/wp-json\/wp\/v2\/tags?post=2003"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}