0f3e251aa704f42bc0f5ba375a6762906ef5b957
[lhc/ateliers.git] / etc / nginx / site.d / lhc-www-tls / configure.sh
1 #!/bin/sh
2 set -e -f -u -x
3 local hint="run vm_remote nginx_configure before"
4 assert "sudo test -f /etc/nginx/x509.d/\"$site\"/key.pem" hint
5 sudo install -m 664 -o www -g www \
6 "$tool"/var/pub/x509/www.heureux-cyclage.org/crt+ca.pem \
7 /etc/nginx/x509.d/"$site"/crt.pem
8
9 sudo rmdir ~www-data/"$site" || true
10 sudo ln -fns "${site%-tls}" ~www-data/"$site"
11