mirror of
https://gitlab.com/psuapp/psu.git
synced 2024-08-30 18:12:34 +00:00
Use the realpath of the env file to be able to source it
Without this commit: This command works correctly: psu -a deploy -u admin -p password -l http://portainer.local -n mystack -c /path/to/docker-compose.yml -g ./env_vars But this command doesn't work correctly: psu -a deploy -u admin -p password -l http://portainer.local -n mystack -c /path/to/docker-compose.yml -g env_vars
This commit is contained in:
parent
0828e59bc7
commit
e386126466
2
psu
2
psu
@ -470,7 +470,7 @@ undeploy() {
|
||||
# JSON string #
|
||||
###################################################
|
||||
env_file_to_json() {
|
||||
echo "$(env -i sh -c "(unset \$(env | sed 's/=.*//'); set -a; . $ENVIRONMENT_VARIABLES_FILE; set +a; jq -njc 'env | to_entries | map({name: .key, value: .value})')")"
|
||||
echo "$(env -i sh -c "(unset \$(env | sed 's/=.*//'); set -a; . $(readlink -f $ENVIRONMENT_VARIABLES_FILE); set +a; jq -njc 'env | to_entries | map({name: .key, value: .value})')")"
|
||||
}
|
||||
|
||||
main "$@"
|
||||
|
Loading…
Reference in New Issue
Block a user