2025-01-25 11:41:12 +01:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
openssl req -x509 -sha256 -nodes -newkey rsa:4096 -days 365 \
|
|
|
|
-keyout localhost.key -out localhost.crt \
|
|
|
|
-subj "/CN=$DOMAIN_NAME/emailAddress=$ADMIN_EMAIL/C=FR/ST=Grand-Est/L=Mulhouse/O=42"
|
|
|
|
|
|
|
|
mkdir -p /etc/ssl/nginx
|
|
|
|
openssl dhparam -out /etc/ssl/nginx/dh2048.pem 2048
|
|
|
|
|
2025-01-25 16:40:18 +01:00
|
|
|
sed -i s/example.com/$DOMAIN_NAME/g /etc/nginx/http.d/example.com.conf
|
2025-01-25 11:41:12 +01:00
|
|
|
|
|
|
|
exec nginx
|