mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-03-18 15:00:00 +00:00

The env var now only affects the bot container, not the API. This is because we don't currently need this extra debug information for the API. For the bot, with DEBUG set, the bot container will now start and do nothing. To start the bot in this container in debug mode, open a shell into the container and run the start-bot-prod-debug script manually. This change was made to allow more control over what profiling scripts and other things are run in the debug environment.
13 lines
375 B
Bash
13 lines
375 B
Bash
#!/bin/bash
|
|
|
|
# This wrapper script is used to run different things based on the DEBUG env variable
|
|
# Exec is used to forward signals: https://unix.stackexchange.com/a/196053
|
|
|
|
cd /zeppelin/backend
|
|
if [ -n "$DEBUG" ]; then
|
|
echo "DEBUG MODE: Starting bot container without starting the bot"
|
|
exec tail -f /dev/null
|
|
else
|
|
echo "Starting bot"
|
|
exec npm run start-bot-prod
|
|
fi
|