fixes to domain in cert generation
This commit is contained in:
parent
d256585284
commit
54876c5499
|
@ -20,7 +20,7 @@ if [ "${CERT_PRIV_KEY}" != '' ] || [ "${CERT_PUB_KEY}" != '' ]; then
|
|||
else
|
||||
# generate a self signed cert
|
||||
if [ ! -f "${CERT_PRIV_PATH}" ] || [ ! -f "${CERT_PUB_PATH}" ]; then
|
||||
rootdomain=$(echo ${API_HOST} | cut -d "." -f 2,3 )
|
||||
rootdomain=$(echo ${API_HOST} | cut -d "." -f2- )
|
||||
openssl req -newkey rsa:4096 -x509 -sha256 -days 365 -nodes -out ${CERT_PUB_PATH} -keyout ${CERT_PRIV_PATH} -subj "/C=US/ST=Some-State/L=city/O=Internet Widgits Pty Ltd/CN=*.${rootdomain}"
|
||||
fi
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue