all-in-one/Containers/whiteboard/start.sh
Simon L. e29d1408fe whiteboard: create required chrome directories on the fly
Signed-off-by: Simon L. <szaimen@e.mail.de>
2025-11-24 14:52:14 +01:00

21 lines
483 B
Bash

#!/bin/bash
# Only start container if nextcloud is accessible
while ! nc -z "$REDIS_HOST" 6379; do
echo "Waiting for redis to start..."
sleep 5
done
# Create required directories
mkdir -p /tmp/chromium-runtime
mkdir -p /tmp/chrome-crashpad
# Set a default for redis db index
if [ -z "$REDIS_DB_INDEX" ]; then
REDIS_DB_INDEX=0
fi
export REDIS_URL="redis://$REDIS_USER:$REDIS_HOST_PASSWORD@$REDIS_HOST/$REDIS_DB_INDEX"
# Run it
exec npm --prefix /app run server:start