From 749de829d5bad6a05ebe1a733a6bd942c1a386ec Mon Sep 17 00:00:00 2001 From: Ivan Gabaldon Date: Fri, 16 May 2025 11:16:41 +0200 Subject: [mod] container: refactor entrypoint script That entrypoint is prone to screw things up, especially with permission handling. The new script handles initialization better and fixes some issues like delayed settings update via ENVs and timestamp overwriting, also adjusts what should be copied into the container. Related https://github.com/searxng/searxng/pull/4721#issuecomment-2850272129 --- utils/lib_sxng_container.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'utils') diff --git a/utils/lib_sxng_container.sh b/utils/lib_sxng_container.sh index 6e29a3809..fd0d072e2 100644 --- a/utils/lib_sxng_container.sh +++ b/utils/lib_sxng_container.sh @@ -114,7 +114,6 @@ container.build() { # shellcheck disable=SC2086 "$container_engine" $params_build_builder \ --build-arg="TIMESTAMP_SETTINGS=$(git log -1 --format="%cd" --date=unix -- ./searx/settings.yml)" \ - --build-arg="TIMESTAMP_UWSGI=$(git log -1 --format="%cd" --date=unix -- ./container/uwsgi.ini)" \ --tag="localhost/$CONTAINER_IMAGE_ORGANIZATION/$CONTAINER_IMAGE_NAME:builder" \ --file="./container/$dockerfile" \ . @@ -122,6 +121,8 @@ container.build() { # shellcheck disable=SC2086 "$container_engine" $params_build \ + --build-arg="TIMESTAMP_SETTINGS=$(git log -1 --format="%cd" --date=unix -- ./searx/settings.yml)" \ + --build-arg="TIMESTAMP_UWSGI=$(git log -1 --format="%cd" --date=unix -- ./container/config/uwsgi.ini)" \ --build-arg="GIT_URL=$GIT_URL" \ --build-arg="SEARXNG_GIT_VERSION=$VERSION_STRING" \ --build-arg="LABEL_DATE=$(date -u +%Y-%m-%dT%H:%M:%SZ)" \ -- cgit v1.2.3