Przeglądaj źródła

Make bin/setup-ssl no tty

Mark Shust 5 lat temu
rodzic
commit
f1930c9770
1 zmienionych plików z 4 dodań i 4 usunięć
  1. 4 4
      compose/bin/setup-ssl

+ 4 - 4
compose/bin/setup-ssl

@@ -2,15 +2,15 @@
 [ -z "$1" ] && echo "Please specify a domain (ex. mydomain.test)" && exit
 [ -z "$1" ] && echo "Please specify a domain (ex. mydomain.test)" && exit
 
 
 # Generate certificate authority if not already setup
 # Generate certificate authority if not already setup
-if ! docker-compose exec -u root app cat /root/.local/share/mkcert/rootCA.pem | grep -q 'BEGIN CERTIFICATE'; then
+if ! docker-compose exec -T -u root app cat /root/.local/share/mkcert/rootCA.pem | grep -q 'BEGIN CERTIFICATE'; then
   bin/setup-ssl-ca
   bin/setup-ssl-ca
 fi
 fi
 
 
 # Generate the certificate for the specified domain
 # Generate the certificate for the specified domain
-docker-compose exec -u root app mkcert -key-file nginx.key -cert-file nginx.crt "$@"
+docker-compose exec -T -u root app mkcert -key-file nginx.key -cert-file nginx.crt "$@"
 echo "Moving key and cert to /etc/nginx/certs/..."
 echo "Moving key and cert to /etc/nginx/certs/..."
-docker-compose exec -u root app chown app:app nginx.key nginx.crt
-docker-compose exec -u root app mv nginx.key nginx.crt /etc/nginx/certs/
+docker-compose exec -T -u root app chown app:app nginx.key nginx.crt
+docker-compose exec -T -u root app mv nginx.key nginx.crt /etc/nginx/certs/
 
 
 # Restart nginx to apply the updates
 # Restart nginx to apply the updates
 echo "Restarting containers to apply updates..."
 echo "Restarting containers to apply updates..."