Compare commits

..

2 Commits

Author SHA1 Message Date
3d50d99368 fix: remove ssl entries if skipping certbot
Some checks failed
Continuous Delivery / build_n_upload (push) Has been cancelled
2026-04-04 06:59:18 +02:00
3a9d39de4c doc: fix dnf command search 2026-04-04 06:47:43 +02:00
2 changed files with 6 additions and 1 deletions

View File

@@ -72,7 +72,7 @@ Some commands to deploy the RPM package on server
- Show available versions: - Show available versions:
```shell ```shell
dnf --showduplicates netoik-rp dnf search --showduplicates netoik-rp
``` ```
- Create certbot ovh credentials here: - Create certbot ovh credentials here:

View File

@@ -23,6 +23,7 @@ Install the reverse proxy called nginx with a predefined configuration and with
%post %post
if [ -z $SKIP_CERTBOT ]; then if [ -z $SKIP_CERTBOT ]; then
# Check required OVH variables
if [ -z $OVH_ENDPOINT ]; then echo "Missing env var OVH_ENDPOINT!" 1>&2; exit 1; fi if [ -z $OVH_ENDPOINT ]; then echo "Missing env var OVH_ENDPOINT!" 1>&2; exit 1; fi
if [ -z $OVH_APPLICATION_NAME ]; then echo "Missing env var OVH_APPLICATION_KEY!" 1>&2; exit 1; fi if [ -z $OVH_APPLICATION_NAME ]; then echo "Missing env var OVH_APPLICATION_KEY!" 1>&2; exit 1; fi
if [ -z $OVH_APPLICATION_DESCRIPTION ]; then echo "Missing env var OVH_APPLICATION_DESCRIPTION!" 1>&2; exit 1; fi if [ -z $OVH_APPLICATION_DESCRIPTION ]; then echo "Missing env var OVH_APPLICATION_DESCRIPTION!" 1>&2; exit 1; fi
@@ -51,6 +52,10 @@ if [ -z $SKIP_CERTBOT ]; then
if [ ! -f "%{_sysconfdir}/letsencrypt/ssl-dhparams.pem" ]; then if [ ! -f "%{_sysconfdir}/letsencrypt/ssl-dhparams.pem" ]; then
openssl dhparam -out %{_sysconfdir}/letsencrypt/ssl-dhparams.pem 2048 openssl dhparam -out %{_sysconfdir}/letsencrypt/ssl-dhparams.pem 2048
fi fi
else
# Skipping certbot, so remove certificate entries in nginx conf
sed --in-place 's/^ssl_certificate/# ssl_certificate/g' %{_sysconfdir}/nginx/conf.d/0_security.conf
fi fi
# Restart services # Restart services