mirror of https://github.com/MISP/misp-docker
add subject alternative names to self-siged certificate (#30)
parent
940e9e6e73
commit
92c22192dc
|
@ -248,7 +248,8 @@ init_nginx() {
|
|||
|
||||
if [[ ! -f /etc/nginx/certs/cert.pem || ! -f /etc/nginx/certs/key.pem ]]; then
|
||||
echo "... generating new self-signed TLS certificate"
|
||||
openssl req -x509 -subj '/CN=localhost' -nodes -newkey rsa:4096 -keyout /etc/nginx/certs/key.pem -out /etc/nginx/certs/cert.pem -days 365
|
||||
openssl req -x509 -subj '/CN=localhost' -nodes -newkey rsa:4096 -keyout /etc/nginx/certs/key.pem -out /etc/nginx/certs/cert.pem -days 365 \
|
||||
-addext "subjectAltName = DNS:localhost, IP:127.0.0.1, IP:::1"
|
||||
else
|
||||
echo "... TLS certificates found"
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue