Skip to content

Instantly share code, notes, and snippets.

@marcosdiez
Created August 14, 2018 00:34
Show Gist options
  • Save marcosdiez/3304155c897c253ad6c97392e4123897 to your computer and use it in GitHub Desktop.
Save marcosdiez/3304155c897c253ad6c97392e4123897 to your computer and use it in GitHub Desktop.
DOMAIN="www.mydomain.com"
if [[ ! -f "${DOMAIN}.key" ]]
then
echo "x"
openssl req -new -newkey rsa:4096 -nodes -keyout ${DOMAIN}.key -out ${DOMAIN}.csr
fi
echo Y
cp ${DOMAIN}.crt ${DOMAIN}_combined.crt
echo "" >> ${DOMAIN}_combined.crt
cat COMODO_RSA_Certification_Authority.crt >> ${DOMAIN}_combined.crt
echo "" >> ${DOMAIN}_combined.crt
cat AddTrust_External_CA_Root.crt >> ${DOMAIN}_combined.crt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment