🗃️ Committing everything that changed 🗃️
Some checks failed
release-tag / release-image (push) Failing after 13m37s

Dockerfile
Dockerfile.cherokee
Dockerfile.final
Dockerfile.nossl
Dockerfile.selective
Dockerfile.stable
Dockerfile.ubuntu
Dockerfile.zevenet
.env.scripts
.gitignore
rootfs/.gitea/workflows/docker.yaml
rootfs/usr/local/bin/entrypoint.sh
rootfs/usr/local/etc/docker/functions/entrypoint.sh
rootfs/usr/local/share/template-files/config/env/default.sample
This commit is contained in:
casjay
2025-09-16 19:36:57 -04:00
parent f2c994b22e
commit b14b239a5f
14 changed files with 212 additions and 575 deletions

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env bash
# shellcheck shell=bash
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
##@Version : 202509052348-git
##@Version : 202509161146-git
# @@Author : Jason Hempstead
# @@Contact : jason@casjaysdev.pro
# @@License : WTFPL
# @@License : LICENSE.md
# @@ReadME : entrypoint.sh --help
# @@Copyright : Copyright: (c) 2025 Jason Hempstead, Casjays Developments
# @@Created : Friday, Sep 05, 2025 23:48 EDT
# @@Created : Tuesday, Sep 16, 2025 11:46 EDT
# @@File : entrypoint.sh
# @@Description : Entrypoint file for cherokee
# @@Changelog : New script
@@ -18,7 +18,7 @@
# @@sudo/root : no
# @@Template : other/docker-entrypoint
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# shellcheck disable=SC1003,SC2016,SC2031,SC2120,SC2155,SC2199,SC2317
# shellcheck disable=SC1001,SC1003,SC2001,SC2003,SC2016,SC2031,SC2120,SC2155,SC2199,SC2317,SC2329
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
set -e
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@@ -87,7 +87,7 @@ SERVICE_UID="${SERVICE_UID:-0}" # set the user id
SERVICE_GID="${SERVICE_GID:-0}" # set the group id
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# User and group in which the service switches to - IE: nginx,apache,mysql,postgres
SERVICE_USER="${SERVICE_USER:-cherokee}" # execute command as another user
SERVICE_USER="${SERVICE_USER:-$cherokee}" # execute command as another user
SERVICE_GROUP="${SERVICE_GROUP:-cherokee}" # Set the service group
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Secondary ports
@@ -259,6 +259,8 @@ if [ -f "$ENTRYPOINT_PID_FILE" ]; then
touch "$ENTRYPOINT_PID_FILE"
else
echo "$$" >"$ENTRYPOINT_PID_FILE"
# Clean any stale PID files on first run
rm -f /run/init.d/*.pid 2>/dev/null || true
fi
if [ -f "$ENTRYPOINT_INIT_FILE" ]; then
ENTRYPOINT_MESSAGE="no" ENTRYPOINT_FIRST_RUN="no"
@@ -370,8 +372,14 @@ if [ "$ENTRYPOINT_FIRST_RUN" != "no" ]; then
__setup_mta
fi
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# if no pid assume container restart
[ -f "$ENTRYPOINT_PID_FILE" ] && [ -f "/run/__start_init_scripts.pid" ] || START_SERVICES="yes"
# if no pid assume container restart - clean stale files on restart
if [ ! -f "$ENTRYPOINT_PID_FILE" ]; then
START_SERVICES="yes"
# Clean stale pid files from previous container runs
rm -f /run/__start_init_scripts.pid /run/init.d/*.pid /run/*.pid 2>/dev/null || true
elif [ ! -f "/run/__start_init_scripts.pid" ]; then
START_SERVICES="yes"
fi
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
[ "$ENTRYPOINT_MESSAGE" = "yes" ] && __printf_space "40" "Container ip address is:" "$CONTAINER_IP4_ADDRESS"
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -