-
Notifications
You must be signed in to change notification settings - Fork 3
Description
Issue Overview:
In the default container startup script located at /opt/startup/init_container.sh, the line service nginx restart triggers a restart of the Nginx service before the custom startup command is executed. This unintended behavior leads to the container entering a restart loop, preventing the custom startup command from ever executing successfully.
Root Cause Analysis:
The script’s current logic first restarts Nginx using the command service nginx restart. (This can be changed to reload instead of restart)
This action causes the container to restart prematurely, interrupting the execution flow.
As a result, the container fails to proceed to the subsequent exec "$@" command, which is intended to execute the user-defined startup command.
Impact:
Custom startup commands never execute, rendering the container unable to perform intended operations.