Docker compose and container stuff

This commit is contained in:
Eduardo Silva 2024-04-04 15:11:13 -03:00
parent 7332bca96e
commit 563ee7408e
12 changed files with 187 additions and 2 deletions

View file

@ -0,0 +1,12 @@
#!/bin/sh
CERT_DIR="/certificate"
if [ ! -f "$CERT_DIR/nginx.key" ] || [ ! -f "$CERT_DIR/nginx.pem" ]; then
echo "Creating self signed certificate..."
openssl req -x509 -newkey rsa:4096 -nodes -keyout "$CERT_DIR/nginx.key" -out "$CERT_DIR/nginx.pem" -days 3650 -subj "/CN=localhost"
else
echo "Skipping self signed certificate creation, files already exist."
fi
exec "$@"