arcanum_jp’s blog

おっさんの日記

wgetで証明書関連エラーでwordpressのzipがダウンロードできなかった

ワードプレスの勉強にとワードプレスをダウンロードしようとこんな感じでwgetするとERROR: cannot verify ja.wordpress.org's certificate・・・ん?エラーなんでだ?昨日は普通にダウンロードできていたで?内容から証明書関連かな?ダルい・・・と困っていたところ、、、

root@1795879ccfeb:/var/www# wget https://ja.wordpress.org/wordpress-5.4.1-ja.zip                        
--2020-06-12 02:24:41--  https://ja.wordpress.org/wordpress-5.4.1-ja.zip
Resolving ja.wordpress.org (ja.wordpress.org)... 198.143.164.252
Connecting to ja.wordpress.org (ja.wordpress.org)|198.143.164.252|:443... connected.
ERROR: cannot verify ja.wordpress.org's certificate, issued by 'CN=Go Daddy Secure Certificate Authority - G2,OU=http://certs.godaddy.com/repository/,O=GoDaddy.com\\, Inc.,L=Scottsdale,ST=Arizona,C=US':
  Unable to locally verify the issuer's authority.
To connect to ja.wordpress.org insecurely, use `--no-check-certificate'.


お!あるじぇねぇか!--no-check-certificateを付けて実行しろと・・・

To connect to ja.wordpress.org insecurely, use `--no-check-certificate'.

ということで--no-check-certificateを付けて実行すれば取れました。DockerfileとかにまとめていてURLの内容が確実ならいんじゃね・・・(( ̄δ・ ̄)ホジホジ

root@1795879ccfeb:/var/www# wget https://ja.wordpress.org/wordpress-5.4.1-ja.zip  --no-check-certificate
--2020-06-12 02:30:27--  https://ja.wordpress.org/wordpress-5.4.1-ja.zip
Resolving ja.wordpress.org (ja.wordpress.org)... 198.143.164.252
Connecting to ja.wordpress.org (ja.wordpress.org)|198.143.164.252|:443... connected.
WARNING: cannot verify ja.wordpress.org's certificate, issued by 'CN=Go Daddy Secure Certificate Authority - G2,OU=http://certs.godaddy.com/repository/,O=GoDaddy.com\\, Inc.,L=Scottsdale,ST=Arizona,C=US':
  Unable to locally verify the issuer's authority.
HTTP request sent, awaiting response... 200 OK
Length: 13960922 (13M) [application/zip]
Saving to: 'wordpress-5.4.1-ja.zip.1'

wordpress-5.4.1-ja.zip.1                      53%[=================================================>                                             ]   7.12M   214KB/s    eta 16s