Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
23 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
#!/bin/bash | ||
|
||
if [ -z $1 ] | ||
then | ||
echo "Usage: bash gen-cert.sh [domain name]" | ||
exit 1 | ||
fi | ||
|
||
docker exec -ti nginx-https-proxy_app_1 certbot --nginx --no-redirect -d $1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/bin/bash | ||
|
||
if [ -z $1 ] | ||
then | ||
echo "Usage: bash gen-self-signed-cert.sh [domain name]" | ||
exit 1 | ||
fi | ||
|
||
sudo mkdir -p letsencrypt/live/$1/ | ||
|
||
sudo openssl req -x509 -newkey rsa:4096 \ | ||
-keyout letsencrypt/live/$1/privkey.pem \ | ||
-out letsencrypt/live/$1/fullchain.pem \ | ||
-days 365 -nodes -subj '/CN=$1' |