initial commit
This commit is contained in:
22
docker-entrypoint.sh
Normal file
22
docker-entrypoint.sh
Normal file
@@ -0,0 +1,22 @@
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
echo "=== Puzzle Generator Container Starting ==="
|
||||
echo "Time: $(date)"
|
||||
echo "Output directory: ${OUT_DIR}"
|
||||
echo "Puzzles per day: ${PUZZLES_PER_DAY}"
|
||||
echo ""
|
||||
|
||||
# Ensure output directory exists
|
||||
mkdir -p "${OUT_DIR}"
|
||||
|
||||
# Generate initial puzzle on startup (optional)
|
||||
if [ "${GENERATE_ON_START}" = "true" ]; then
|
||||
echo "Generating initial puzzles..."
|
||||
java -cp /app/target puzzle.DailyGenerator
|
||||
echo ""
|
||||
fi
|
||||
|
||||
# Start cron scheduler
|
||||
echo "Starting cron scheduler..."
|
||||
exec /usr/local/bin/supercronic /app/crontab
|
||||
Reference in New Issue
Block a user