diff --git a/images/linux/scripts/installers/pipx-packages.sh b/images/linux/scripts/installers/pipx-packages.sh index 67931b591..77308fa33 100644 --- a/images/linux/scripts/installers/pipx-packages.sh +++ b/images/linux/scripts/installers/pipx-packages.sh @@ -5,7 +5,7 @@ ################################################################################ -export PATH="$PATH:/opt/pipx_bin" +# export PATH="$PATH:/opt/pipx_bin" # Install yamlint pipx install yamllint diff --git a/images/linux/scripts/installers/python.sh b/images/linux/scripts/installers/python.sh index 6472de40b..726515676 100644 --- a/images/linux/scripts/installers/python.sh +++ b/images/linux/scripts/installers/python.sh @@ -6,6 +6,7 @@ set -e # Source the helpers for use with the script +source $HELPER_SCRIPTS/etc-environment.sh source $HELPER_SCRIPTS/os.sh # Install Python, Python 3, pip, pip3 @@ -26,8 +27,12 @@ export PIPX_HOME=/opt/pipx python3 -m pip install pipx python3 -m pipx ensurepath -echo "PIPX_BIN_DIR=$PIPX_BIN_DIR" | tee -a /etc/environment -echo "PIPX_HOME=$PIPX_HOME" | tee -a /etc/environment +# Update /etc/environment +setEtcEnvironmentVariable "PIPX_BIN_DIR" $PIPX_BIN_DIR +setEtcEnvironmentVariable "PIPX_HOME" $PIPX_HOME +prependEtcEnvironmentPath /opt/pipx_bin +# echo "PIPX_BIN_DIR=$PIPX_BIN_DIR" | tee -a /etc/environment +# echo "PIPX_HOME=$PIPX_HOME" | tee -a /etc/environment # Add pipx bin directory to path # export PATH="$PATH:$PIPX_BIN_DIR"