Skip to content

Instantly share code, notes, and snippets.

@pantuts
Created September 12, 2016 04:28
Show Gist options
  • Save pantuts/e34a471859f7cc3035a8fefcfc31dc4b to your computer and use it in GitHub Desktop.
Save pantuts/e34a471859f7cc3035a8fefcfc31dc4b to your computer and use it in GitHub Desktop.
# https://github.com/hughperkins/howto-jenkins-ssl
openssl genrsa -out key.pem # creates key.pem
openssl req -new -key key.pem -out csr.pem
# you need to put the dns name of your website, testweb.local
# for the 'Common Name' question
# other questions, you can just accept defaults
# actually, you can accept defaults for all, will work ok too
openssl x509 -req -days 9999 -in csr.pem -signkey key.pem -out cert.pem
rm csr.pem
# vi /etc/sysconfig/jenkins
JENKINS_ARGS="--httpsPort=8443 --httpsCertificate=cert.pem --httpsPrivateKey=key.pem --httpPort=-1"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment