From bd5c8b2840036299de1e79b5732d7a501aa94819 Mon Sep 17 00:00:00 2001 From: casjay Date: Sat, 7 Sep 2024 12:34:01 -0400 Subject: [PATCH] =?UTF-8?q?=F0=9F=97=83=EF=B8=8F=20Committing=20everything?= =?UTF-8?q?=20that=20changed=20=F0=9F=97=83=EF=B8=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit rootfs/usr/local/bin/entrypoint.sh rootfs/usr/local/etc/docker/init.d/00-mysqld.sh rootfs/usr/local/etc/docker/init.d/05-nginx.sh --- rootfs/usr/local/bin/entrypoint.sh | 4 ++-- rootfs/usr/local/etc/docker/init.d/00-mysqld.sh | 2 +- rootfs/usr/local/etc/docker/init.d/05-nginx.sh | 8 ++++---- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/rootfs/usr/local/bin/entrypoint.sh b/rootfs/usr/local/bin/entrypoint.sh index 8a1b559..b814017 100755 --- a/rootfs/usr/local/bin/entrypoint.sh +++ b/rootfs/usr/local/bin/entrypoint.sh @@ -82,10 +82,10 @@ SERVICE_UID="0" # set the user id SERVICE_GID="0" # set the group id # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Primary server port- will be added to server ports -WEB_SERVER_PORT="" # port : 80,443 +WEB_SERVER_PORT="80" # port : 80,443 # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Secondary ports -SERVER_PORTS="" # specifiy other ports +SERVER_PORTS="3306" # specifiy other ports # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Server directories WWW_ROOT_DIR="" # set default web dir diff --git a/rootfs/usr/local/etc/docker/init.d/00-mysqld.sh b/rootfs/usr/local/etc/docker/init.d/00-mysqld.sh index d9b1381..219b1b1 100755 --- a/rootfs/usr/local/etc/docker/init.d/00-mysqld.sh +++ b/rootfs/usr/local/etc/docker/init.d/00-mysqld.sh @@ -186,7 +186,7 @@ __run_pre_execute_checks() { # Put command to execute in parentheses { if [ ! -d "$DATABASE_DIR" ] || [ ! -f "$DATABASE_DIR/ibdata1" ]; then - rm -Rf "$DATABASE_DIR" + rm -Rf "${DATABASE_DIR:?}"/* mkdir -p "$DATABASE_DIR" chown -Rf $SERVICE_USER:$SERVICE_GROUP "$DATABASE_DIR" mysql_install_db --datadir=$DATABASE_DIR --user=$SERVICE_USER 2>/dev/null diff --git a/rootfs/usr/local/etc/docker/init.d/05-nginx.sh b/rootfs/usr/local/etc/docker/init.d/05-nginx.sh index 175a27e..8e8ee4d 100755 --- a/rootfs/usr/local/etc/docker/init.d/05-nginx.sh +++ b/rootfs/usr/local/etc/docker/init.d/05-nginx.sh @@ -107,12 +107,12 @@ RUNAS_USER="root" # normally root #SERVICE_GID="0" # set the group id # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # execute command variables - keep single quotes variables will be expanded later -EXEC_CMD_BIN='nginx' # command to execute -EXEC_CMD_ARGS='-c $CONF_DIR/nginx.conf' # command arguments -EXEC_PRE_SCRIPT='' # execute script before +EXEC_CMD_BIN='nginx' # command to execute +EXEC_CMD_ARGS='-c $ETC_DIR/nginx.conf' # command arguments +EXEC_PRE_SCRIPT='' # execute script before # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Is this service a web server -IS_WEB_SERVER="no" +IS_WEB_SERVER="yes" # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # Is this service a database server IS_DATABASE_SERVICE="no"