From b0fdeae6d2cf692e98dd42a8a18fccf33cfa84fd Mon Sep 17 00:00:00 2001 From: Franco Fichtner Date: Wed, 13 Nov 2024 16:06:31 +0100 Subject: [PATCH] Revert "firmware: when calling one of the predefined commands via our launcher, the environment should be initialized." This reverts commit 1ff4c95f115028cd3786f249ef77500767c904bf. Intended side effect so that the launcher will have access to the vars published by config.sh -- when the launcher starts the actual script the script itself will source the config.sh again causing the env_init() to be called for all participating COMMANDS. This ensures the env_init() call is locked by default. --- src/opnsense/scripts/firmware/config.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/opnsense/scripts/firmware/config.sh b/src/opnsense/scripts/firmware/config.sh index d52bfefe3..e3bbf2e5b 100755 --- a/src/opnsense/scripts/firmware/config.sh +++ b/src/opnsense/scripts/firmware/config.sh @@ -30,7 +30,7 @@ LOCKFILE=${LOCKFILE:-/tmp/pkg_upgrade.progress} BASEDIR="/usr/local/opnsense/scripts/firmware" PIPEFILE="/tmp/pkg_upgrade.pipe" FLOCK="/usr/local/bin/flock" -SELF=$(basename ${1%.sh}) +SELF=$(basename ${0%.sh}) PKG="/usr/local/sbin/pkg" TEE="/usr/bin/tee -a" PRODUCT="OPNsense"