zxlie / website-ssl.sh Goto Github PK
View Code? Open in Web Editor NEW低门槛跨入Https大门!网站ssl证书自动生成工具(http到https的转变),燥起来吧!
Home Page: https://www.baidufe.com
低门槛跨入Https大门!网站ssl证书自动生成工具(http到https的转变),燥起来吧!
Home Page: https://www.baidufe.com
运行 sh website-ssl.sh
提示如标题。
21
行是:
function install_config(){
环境:
在执行 sh website-ssl.sh pem 后,
只生成了一个account.key 与 domain.key
然后nginx里的配置就报错...
nginx: [emerg] BIO_new_file("/home/www/ssl/ssl-encrypt.pem") failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen('/home/www/ssl/ssl-encrypt.pem','r') error:2006D080:BIO routines:BIO_new_file:no such file)
nginx: configuration file /usr/local/nginx/conf/nginx.conf test failed
Parsing account key...
Parsing CSR...
Traceback (most recent call last):
File "libs/acme_tiny.py", line 198, in
main(sys.argv[1:])
File "libs/acme_tiny.py", line 194, in main
signed_crt = get_crt(args.account_key, args.csr, args.acme_dir, log=LOGGER, CA=args.ca)
File "libs/acme_tiny.py", line 70, in get_crt
raise IOError("Error loading {0}: {1}".format(csr, err))
IOError: Error loading domain.csr: unable to load X509 request
140591088047944:error:0906D06C:PEM routines:PEM_read_bio:no start line:pem_lib.c:703:Expecting: CERTIFICATE REQUEST
raise ValueError("Wrote file to {0}, but couldn't download {1}: {2}".format(wellknown_path, wellknown_url, e))
ValueError: Wrote file to /home/www/ssl/challenges/UyHBjNfJd, but couldn't download http://xxx.com/.well-known/acme-challenge/UyHBjNfJd
website-ssl.sh: 21: website-ssl.sh: Syntax error: "(" unexpected #2
执行了
chmod 0755 website-ssl.sh
./website-ssl.sh
似乎只能用 bash website-ssl.sh
来执行,sh
还不行。
nginx: [emerg] SSL_CTX_use_PrivateKey_file("/home/work/www/ssl/domain.key") failed (SSL: error:0B080074:x509 certificate routines:X509_check_private_key:key values mismatch)
当执行./website-ssl.sh pem
时,
第98行错误
python libs/acme_tiny.py --account-key account.key --csr domain.csr --acme-dir $challenges_dir > signed.crt
当前目录已经发生变化,找不到libs/acme_tiny.py运行错误。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.