diff --git a/delay_price.sh b/delay_price.sh new file mode 100644 index 0000000..2515c71 --- /dev/null +++ b/delay_price.sh @@ -0,0 +1,6 @@ +#!/bin/bash +source /app/env +printenv +sleep 2 + +python3 /app/get_price.py >> /var/log/cron.log 2>&1 \ No newline at end of file diff --git a/start.sh b/start.sh new file mode 100644 index 0000000..6632127 --- /dev/null +++ b/start.sh @@ -0,0 +1,11 @@ +#!/bin/bash +printenv > /app/env +# Start the cron service +service cron start + +# Run your main application script (pulse.py) in the background +python3 /app/pulse.py & + +# Keep the container running and output both cron logs and pulse.py output +tail -f /var/log/cron.log & +wait -n