Fixed cert generation.

This commit is contained in:
Emilis Dambauskas 2020-12-01 04:02:34 +02:00
parent 02f78e9437
commit 6371db1eaf
1 changed files with 5 additions and 3 deletions

View File

@ -1,5 +1,4 @@
CERT_DAYS=10000
COUNTRY=LT
DOMAIN=localhost
SERVE_REQUEST="./serve-request.sh"
@ -48,8 +47,11 @@ certs: \
certs/${DOMAIN}.crt: certs/${DOMAIN}.key
mkdir -p certs
echo -en ".\n.\n.\n.\n.\n${DOMAIN}\n.\n" | \
openssl req -x509 -key "certs/${DOMAIN}.key" -out "$@" -days ${CERT_DAYS} -nodes
echo -en ".\n.\n.\n.\n.\n.\n${DOMAIN}\n.\n" \
| openssl req -x509 -nodes \
-days ${CERT_DAYS} \
-key "certs/${DOMAIN}.key" \
-out "certs/${DOMAIN}.crt"
certs/${DOMAIN}.key:
mkdir -p certs