env variables for local command in abra.sh #351

Closed
opened 2022-10-25 17:52:45 +00:00 by moritz · 1 comment
Member

If I execute an abra.sh function locally using abra app command --local <domain> <my_command> I am not able to directly access the environment variables set via abra app config.

Using this workaround I can access the environment variables indirectly:

abra app run -t $APP_NAME app env | {
while read -r line; do
    export "$line"
done
echo $DOMAIN
}

It would be helpful if the environment variables are passed to the execution of local commands.
I think in this line 07d49d8566/cli/app/cmd.go (L80) the environment variables could be passed.

Related: #301

If I execute an abra.sh function locally using `abra app command --local <domain> <my_command>` I am not able to directly access the environment variables set via `abra app config`. Using this workaround I can access the environment variables indirectly: ``` abra app run -t $APP_NAME app env | { while read -r line; do export "$line" done echo $DOMAIN } ``` It would be helpful if the environment variables are passed to the execution of local commands. I think in this line https://git.coopcloud.tech/coop-cloud/abra/src/commit/07d49d8566e84dfd96b82a34287b13ca3b571b90/cli/app/cmd.go#L80 the environment variables could be passed. Related: https://git.coopcloud.tech/coop-cloud/organising/issues/301
moritz added the
enhancement
abra
labels 2022-10-25 17:52:45 +00:00
Owner

Hey @moritz, yes, nice! If you wanna take a shot at a PR, I'd glady review it.

Will try to get this sometime Soon ™️

Nice that you have the work-around 💯

Hey @moritz, yes, nice! If you wanna take a shot at a PR, I'd glady review it. Will try to get this sometime Soon :tm: Nice that you have the work-around 💯
moritz self-assigned this 2022-11-08 12:59:01 +00:00
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: coop-cloud/organising#351
No description provided.