Merge pull request #5730 from JMarcosHP/main

Add apache container reachability check and retry mechanism to run-exec-commands.sh
This commit is contained in:
Simon L. 2024-12-20 11:17:03 +01:00 committed by GitHub
commit 4379446e16
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 9 additions and 4 deletions

View file

@ -1,7 +1,10 @@
#!/bin/bash
# Wait 15s for domain to be reachable
sleep 15
# Wait until the apache container is ready
while ! nc -z "$APACHE_HOST" "$APACHE_PORT"; do
echo "Waiting for Apache to become available..."
sleep 15
done
if [ -n "$NEXTCLOUD_EXEC_COMMANDS" ]; then
echo "#!/bin/bash" > /tmp/nextcloud-exec-commands