{"id":188,"date":"2021-03-12T14:04:06","date_gmt":"2021-03-12T05:04:06","guid":{"rendered":"https:\/\/sirius10.dip.jp\/blog\/wordpress\/?p=188"},"modified":"2021-05-04T16:33:01","modified_gmt":"2021-05-04T07:33:01","slug":"post-188","status":"publish","type":"post","link":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/2021\/03\/12\/188\/","title":{"rendered":"\u30b5\u30fc\u30d0\u7528Raspberry Pi \u306e\u8a2d\u5b9a8"},"content":{"rendered":"\n<p>\u3000\u65b0\u3057\u304f\u30b5\u30a4\u30c8\u3092\u516c\u958b\u3059\u308b\u306a\u3089\u3001hhtp \u3067\u306f\u306a\u304f\u3001https \u3067\u306e\u30b5\u30fc\u30d3\u30b9\u304c\u5fc5\u9808\u3067\u3057\u3087\u3046\u3002<\/p>\n\n\n\n<p>\u3000\u3057\u304b\u3057\u3001\u6b63\u5f0f\u306a https \u306b\u306f\u3001\u8a3c\u660e\u6a5f\u95a2\u306e\u8a3c\u660e\u66f8\u304c\u5fc5\u8981\u306b\u306a\u308a\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u53c2\u8003\uff1a<a href=\"https:\/\/qiita.com\/HO_Pollyanna\/items\/aee45b25e2318d39157b\">https:\/\/qiita.com\/HO_Pollyanna\/items\/aee45b25e2318d39157b<\/a><\/p>\n\n\n\n<p>\u3000Let\u2019s Encrypt \u3068\u3044\u3046\u3082\u306e\u3092\u4f7f\u3063\u3066\u3001https \u3067\u516c\u958b\u3067\u304d\u308b\u3088\u3046\u306b\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p>\u3000\u307e\u305a\u3001\u30eb\u30fc\u30bf\u3067 443 \u756a\u30dd\u30fc\u30c8\u3092\u958b\u3051\u3066\u304a\u304d\u307e\u3059\u3002<br>\u3000\u30eb\u30fc\u30bf\u306e\u8a2d\u5b9a\u753b\u9762\u3067 WAN \u304b\u3089\u304f\u308b 443 \u756a\u30dd\u30fc\u30c8\u306e\u30c7\u30fc\u30bf\u3092 Apache \u304c\u52d5\u3044\u3066\u3044\u308b\u30de\u30b7\u30f3\u306e IP \u30a2\u30c9\u30ec\u30b9\u3078\u632f\u308a\u5206\u3051\u308b\u3088\u3046\u306b\u8a2d\u5b9a\u3059\u308c\u3070 OK \u3067\u3059\u3002<\/p>\n\n\n\n<p>\u3000Certbot \u30af\u30e9\u30a4\u30a2\u30f3\u30c8\u3092\u4f7f\u3046\u3088\u3046\u306a\u306e\u3067\u3001\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"console\">$ sudo apt-get install certbot python-certbot-apache<\/p>\n\n\n\n<p>\u3000\u5b9f\u884c\u3057\u3066\u767b\u9332\u3068\u8a3c\u660e\u66f8\u306e\u53d6\u5f97\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"console\">$ sudo certbot certonly<br>Saving debug log to \/var\/log\/letsencrypt\/letsencrypt.log<br><br>How would you like to authenticate with the ACME CA?<br>&#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211;<br>1: Apache Web Server plugin (apache)<br>2: Spin up a temporary webserver (standalone)<br>3: Place files in webroot directory (webroot)<br>&#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211;<br>Select the appropriate number [1-3] then [enter] (press &#8216;c&#8217; to cancel): 3<br>Plugins selected: Authenticator webroot, Installer None<br>Enter email address (used for urgent renewal and security notices) (Enter &#8216;c&#8217; to cancel): xxxxx@sirius10.dip.jp<br><br>&#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211;<br>Please read the Terms of Service at<br>https:\/\/letsencrypt.org\/documents\/LE-SA-v1.2-November-15-2017.pdf. You must<br>agree in order to register with the ACME server at<br>https:\/\/acme-v02.api.letsencrypt.org\/directory<br>&#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211;<br>(A)gree\/(C)ancel: A<br><br>&#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211;<br>Would you be willing to share your email address with the Electronic Frontier<br>Foundation, a founding partner of the Let&#8217;s Encrypt project and the non-profit<br>organization that develops Certbot? We&#8217;d like to send you email about our work<br>encrypting the web, EFF news, campaigns, and ways to support digital freedom.<br>&#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211; &#8211;<br>(Y)es\/(N)o: y<br>Please enter in your domain name(s) (comma and\/or space separated)  (Enter &#8216;c&#8217; to cancel): sirius10.dip.jp<br>Obtaining a new certificate<br>Performing the following challenges:<br>http-01 challenge for sirius10.dip.jp<br>Input the webroot for sirius10.dip.jp: (Enter &#8216;c&#8217; to cancel): \/var\/www\/sirius10<br>Waiting for verification&#8230;<br>Cleaning up challenges<br><br>IMPORTANT NOTES:<br> &#8211; Congratulations! Your certificate and chain have been saved at:<br>   \/etc\/letsencrypt\/live\/sirius10.dip.jp\/fullchain.pem<br>   Your key file has been saved at:<br>   \/etc\/letsencrypt\/live\/sirius10.dip.jp\/privkey.pem<br>   Your cert will expire on 2021-06-02. To obtain a new or tweaked<br>   version of this certificate in the future, simply run certbot<br>   again. To non-interactively renew *all* of your certificates, run<br>   &#8220;certbot renew&#8221;<br> &#8211; Your account credentials have been saved in your Certbot<br>   configuration directory at \/etc\/letsencrypt. You should make a<br>   secure backup of this folder now. This configuration directory will<br>   also contain certificates and private keys obtained by Certbot so<br>   making regular backups of this folder is ideal.<br> &#8211; If you like Certbot, please consider supporting our work by:<br>\n<br>   Donating to ISRG \/ Let&#8217;s Encrypt:   https:\/\/letsencrypt.org\/donate<br>   Donating to EFF:                    https:\/\/eff.org\/donate-le<br><\/p>\n\n\n\n<p>\u3000\u3053\u308c\u3067\u3001\u8a3c\u660e\u66f8\u306e\u53d6\u5f97\u306f\u3067\u304d\u305f\u306f\u305a\u306a\u306e\u3067\u3001apache \u3092\u8a2d\u5b9a\u3057\u3066\u3044\u304d\u307e\u3059\u3002<br>\u3000\u53c2\u8003\u306b\u3057\u305f\u30da\u30fc\u30b8\u306f\u4eee\u60f3\u30b5\u30a4\u30c8\u3067\u306f\u306a\u3044\u306e\u3067\u3001\u3061\u3087\u3063\u3068\u9055\u3044\u307e\u3059\u3002<br>\u3000\/etc\/apache2\/sites-available \u306b\u79fb\u52d5\u3057\u3001default-ssl.conf \u3092\u53c2\u8003\u306b\u3001sirius10.dip.jp-ssl.conf \u3092\u4f5c\u6210\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p>ssl \u3092\u6709\u52b9\u306b\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"console\">$ sudo a2enmod ssl<br>Considering dependency setenvif for ssl:<br>Module setenvif already enabled<br>Considering dependency mime for ssl:<br>Module mime already enabled<br>Considering dependency socache_shmcb for ssl:<br>Enabling module socache_shmcb.<br>Enabling module ssl.<br>See \/usr\/share\/doc\/apache2\/README.Debian.gz on how to configure SSL and create self-signed certificates.<br>To activate the new configuration, you need to run:<br>systemctl restart apache2<\/p>\n\n\n\n<p>\u30b5\u30a4\u30c8\u3092\u6709\u52b9\u306b\u3057\u307e\u3059 (sites-enabled \u3078\u30ea\u30f3\u30af\u3092\u8cbc\u3063\u3066\u3082 OK)<\/p>\n\n\n\n<p class=\"console\">$ sudo a2ensite sirius10.dip.jp-ssl<\/p>\n\n\n\n<p>Apache \u3092\u518d\u8d77\u52d5\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<p class=\"console\">$ sudo service apache2 restart<\/p>\n\n\n\n<p>\u3000\u30a8\u30e9\u30fc\u304c\u51fa\u3066\u3057\u307e\u3044\u307e\u3057\u305f\u3002sudo systemctl status apache2.service \u3067\u8a73\u7d30\u304c\u898b\u308c\u307e\u3059\u3002<br>\u3000conf \u30d5\u30a1\u30a4\u30eb\u306e\u30a8\u30e9\u30fc\u3067\u3057\u305f\u3002<\/p>\n\n\n\n<p>\u3000Apache \u3092\u518d\u8d77\u52d5\u3057\u3066\u3001https \u3067\u30a2\u30af\u30bb\u30b9\u3057\u3066\u307f\u307e\u3059\u3002<br>\u5927\u4e08\u592b\u3067\u3057\u305f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u3000\u65b0\u3057\u304f\u30b5\u30a4\u30c8\u3092\u516c\u958b\u3059\u308b\u306a\u3089\u3001hhtp \u3067\u306f\u306a\u304f\u3001https \u3067\u306e\u30b5\u30fc\u30d3\u30b9\u304c\u5fc5\u9808\u3067\u3057\u3087\u3046\u3002 \u3000\u3057\u304b\u3057\u3001\u6b63\u5f0f\u306a https \u306b\u306f\u3001\u8a3c\u660e\u6a5f\u95a2\u306e\u8a3c\u660e\u66f8\u304c\u5fc5\u8981\u306b\u306a\u308a\u307e\u3059\u3002 \u53c2\u8003\uff1ahttps:\/\/qiita.com\/HO_Poll [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19],"tags":[],"class_list":["post-188","post","type-post","status-publish","format-standard","hentry","category-web"],"_links":{"self":[{"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/posts\/188","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/comments?post=188"}],"version-history":[{"count":4,"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/posts\/188\/revisions"}],"predecessor-version":[{"id":888,"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/posts\/188\/revisions\/888"}],"wp:attachment":[{"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/media?parent=188"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/categories?post=188"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/sirius10.net\/blog\/wordpress\/index.php\/wp-json\/wp\/v2\/tags?post=188"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}