From ee26db692b27bd9ecde2f7f44d8f600bfed189b6 Mon Sep 17 00:00:00 2001 From: Manuel Gutierrez <1380243+xr09@users.noreply.github.com> Date: Thu, 24 Sep 2020 11:32:51 +0200 Subject: [PATCH] Remove legacy code to run cmd on entrypoint --- .../config/etc/cont-init.d/0-wazuh-init | 20 +------------------ 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/wazuh-opendistro/config/etc/cont-init.d/0-wazuh-init b/wazuh-opendistro/config/etc/cont-init.d/0-wazuh-init index f3fbd1a4..1aa78f65 100644 --- a/wazuh-opendistro/config/etc/cont-init.d/0-wazuh-init +++ b/wazuh-opendistro/config/etc/cont-init.d/0-wazuh-init @@ -126,21 +126,6 @@ function ossec_shutdown(){ ${WAZUH_INSTALL_PATH}/bin/ossec-control stop; } -############################################################################## -# Interpret any passed arguments (via docker command to this entrypoint) as -# paths or commands, and execute them. -# -# This can be useful for actions that need to be run before the services are -# started, such as "/var/ossec/bin/ossec-control enable agentless". -############################################################################## - -docker_custom_args() { - for CUSTOM_COMMAND in "$@" - do - echo "Executing command \`${CUSTOM_COMMAND}\`" - exec_cmd_stdout "${CUSTOM_COMMAND}" - done -} ############################################################################## # Main function @@ -169,10 +154,7 @@ main() { mount_files # Trap exit signals and do a proper shutdown - trap "ossec_shutdown; exit" SIGINT SIGTERM - - # Execute custom args - docker_custom_args + trap "ossec_shutdown; exit" SIGINT SIGTERM # Delete temporary data folder rm -rf ${WAZUH_INSTALL_PATH}/data_tmp