Skip to content

Commit

Permalink
save refeshed certs to new dir
Browse files Browse the repository at this point in the history
  • Loading branch information
itiligent committed Sep 11, 2023
1 parent 9967087 commit 7f0b177
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
6 changes: 6 additions & 0 deletions 4a-install-tls-self-signed-nginx.sh
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@ PROXY_SITE=
CERT_DAYS=
DEFAULT_IP=

# Create a place to save the certs so we don't overwrite any earlier versions
CERT_DIR_NAME=tls-certs-$(date +%y.%m.%d-%H_%M)
CERT_DIR=$DOWNLOAD_DIR/$CERT_DIR_NAME
mkdir -p $CERT_DIR
cd $CERT_DIR

# Setup script cmd line arguments for proxy site and certificate days
TLSNAME=$1
TLSDAYS=$2
Expand Down
9 changes: 5 additions & 4 deletions guac-management/refresh-tls-self-signed.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,12 @@ echo
echo -e "${LGREEN}Cresting self signed TLS certificates for Nginx...${GREY}"
echo

# Create a place to save the certs so we don't overwrite any earlier versions
USER_HOME_DIR=$(eval echo ~${SUDO_USER})
CERT_DIR=tls-certs-$(date +%y.%m.%d-%H_%M)
WORKING_DIR=$USER_HOME_DIR/guac-setup/$CERT_DIR
mkdir -p $WORKING_DIR
cd $WORKING_DIR
CERT_DIR_NAME=tls-certs-$(date +%y.%m.%d-%H_%M)
CERT_DIR=$USER_HOME_DIR/guac-setup/$CERT_DIR_NAME
mkdir -p $CERT_DIR
cd $CERT_DIR

# Set default certificate file destinations. Change these for other TLS applications.
DIR_SSL_KEY="/etc/nginx/ssl/private"
Expand Down

0 comments on commit 7f0b177

Please sign in to comment.