Skip to content

Commit

Permalink
Merge pull request #75 from datosgobar/74-generacion-archivo-dhparams
Browse files Browse the repository at this point in the history
La creación del archivo de DH params se realiza una sola vez
  • Loading branch information
poligarcia authored Nov 26, 2018
2 parents a803eb6 + 3194188 commit 0430390
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions nginx/command.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,22 @@ if [[ -n "$NGINX_CONFIG_FILE" \
&& -f "$NGINX_SSL_CONFIG_DATA/andino.crt" ]]; then
echo "Using '$NGINX_CONFIG_FILE' configuration"
ln -s "$NGINX_AVAILABLE_SITES/$NGINX_CONFIG_FILE" /etc/nginx/conf.d/default.conf;
openssl dhparam 2048 -out $NGINX_SSL_CONFIG_DATA/andino_dhparam.pem
if ! [ -f "$NGINX_SSL_CONFIG_DATA/andino_dhparam.pem" ]
then
echo "Creando archivo de DH params" ;
openssl dhparam 2048 -out $NGINX_SSL_CONFIG_DATA/andino_dhparam.pem ;
else
echo "El archivo de DH params ya existía, por no que no se lo volverá a crear" ;
fi
else
echo "Using '$NGINX_DEFAULT_CONFIG_FILE' default configuration"
ln -s "$NGINX_AVAILABLE_SITES/$NGINX_DEFAULT_CONFIG_FILE" /etc/nginx/conf.d/default.conf;
fi

# Configure extended cache if specified
if [ "$NGINX_EXTENDED_CACHE" = 'yes' ] ; then
chmod -R u+rwx $NGINX_SCRIPTS
chmod -R u+rwx $NGINX_SCRIPTS ;
echo "Aplicando modificaciones para la extensión de la caché"
"$NGINX_SCRIPTS"/extend_nginx.sh ;
fi

Expand Down

0 comments on commit 0430390

Please sign in to comment.