Skip to content

Commit

Permalink
Merge pull request #44 from miguelfc/certbot
Browse files Browse the repository at this point in the history
added certbot script
  • Loading branch information
miguelfc authored May 2, 2017
2 parents 5ebb352 + a3db3be commit 4058327
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions docker/docker-utils/certbot.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
#!/bin/bash

CERT_DIR=/home/marble/certs
LIVE_DIR=$CERT_DIR/live/your.domain.com

mkdir $CERT_DIR && echo "$CERT_DIR recreated"

docker run --rm -it --net docker_default \
-v $CERT_DIR:/etc/letsencrypt \
certbot/certbot \
certonly -d your.domain.com --agree-tos --email your@email.com --manual --preferred-challenges dns

openssl pkcs12 -export -in $LIVE_DIR/fullchain.pem \
-inkey $LIVE_DIR/privkey.pem \
-out ../core-config/keystore.p12 \
-name tomcat \
-CAfile $LIVE_DIR/chain.pem \
-caname root

0 comments on commit 4058327

Please sign in to comment.