wget獲取https資源


使用wget獲取 https資源,缺省命令下是要使用證書,如果還未安裝證書,可以選擇忽略。

  例如沒有github.com的證書,執行如下命令

mkdir -p model
cd model
wget  https://github.com/dmlc/web-data/raw/master/mxnet/neural-style/model/vgg19.params
cd ..

mkdir -p input
cd input
wget https://github.com/dmlc/web-data/raw/master/mxnet/neural-style/input/IMG_4343.jpg
wget  https://github.com/dmlc/web-data/raw/master/mxnet/neural-style/input/starry_night.jpg
cd ..

mkdir -p output

  會報錯,

ERROR: cannot verify github.com's certificate, issued by `/C=US/O=DigiCert Inc/OU=www.digicert.com/CN=DigiCert SHA2 Extended Validation Server CA':
  Unable to locally verify the issuer's authority.
To connect to github.com insecurely, use `--no-check-certificate'.

  此時,加上 --no-check-certificate  選項,忽略證書檢查,如下

#!/bin/bash

mkdir -p model
cd model
wget --no-check-certificate https://github.com/dmlc/web-data/raw/master/mxnet/neural-style/model/vgg19.params
cd ..

mkdir -p input
cd input
wget --no-check-certificate https://github.com/dmlc/web-data/raw/master/mxnet/neural-style/input/IMG_4343.jpg
wget --no-check-certificate https://github.com/dmlc/web-data/raw/master/mxnet/neural-style/input/starry_night.jpg
cd ..

mkdir -p output

  


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM