1
0
Fork 0
mirror of https://github.com/overleaf/toolkit.git synced 2025-04-19 07:18:06 +02:00

Add -subj option to openssl req command

This commit is contained in:
Alf Eaton 2023-04-13 07:59:07 +01:00
parent e93dfe9977
commit a58f9c0ca8

View file

@ -51,7 +51,7 @@ function set_up_tls_proxy() {
echo "Generate example self-signed TLS cert"
mkdir -p config/nginx/certs
cp "$TOOLKIT_ROOT/lib/config-seed/nginx.conf" "$TOOLKIT_ROOT/config/nginx/"
openssl req -new -nodes -keyout "$PRIVATE_KEY" -out "$CERT_SIGN_REQ" -batch
openssl req -new -nodes -keyout "$PRIVATE_KEY" -out "$CERT_SIGN_REQ" -subj "/CN=example.com" -batch
chmod 600 "$PRIVATE_KEY"
openssl x509 -req -days 365 -in "$CERT_SIGN_REQ" -signkey "$PRIVATE_KEY" -out "$CERT"
}