flowdat_deploy.sh 741 B

12345678910111213141516171819202122232425262728
  1. #!/bin/sh
  2. set -e
  3. for domain in $RENEWED_DOMAINS; do
  4. case $domain in
  5. DOMAIN_NAME_REPLACE)
  6. nginx_cert_root=DIRINSTALL/nginx/certs
  7. # Make sure the certificate and private key files are
  8. # never world readable, even just for an instant while
  9. # we're copying them into daemon_cert_root.
  10. umask 077
  11. cp "$RENEWED_LINEAGE/fullchain.pem" "$nginx_cert_root/fullchain.pem"
  12. cp "$RENEWED_LINEAGE/privkey.pem" "$nginx_cert_root/privkey.pem"
  13. # Apply the proper file ownership and permissions for
  14. # the daemon to read its certificate and key.
  15. chmod 400 "$nginx_cert_root/fullchain.pem" \
  16. "$nginx_cert_root/privkey.pem"
  17. cd DIRINSTALL && docker-compose restart nginx
  18. ;;
  19. esac
  20. done
  21. exit 0