Skip to content

Commit

Permalink
fix: grept apply (#34)
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
mbilalamjad and github-actions[bot] authored May 31, 2024
1 parent 8c5a1e1 commit e2e62f5
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion avm
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,10 @@ if [ -z "$1" ]; then
exit 1
fi

$CONTAINER_RUNTIME run --pull always --rm -v "$(pwd)":/src -w /src -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER mcr.microsoft.com/azterraform make "$1"
# Check if we are running in a container
# If we are then just run make directly
if [ -z "$AVM_IN_CONTAINER" ]; then
$CONTAINER_RUNTIME run --pull always --user "$(id -u):$(id -g)" --rm -v /etc/passwd:/etc/passwd -v /etc/group:/etc/group -v "$(pwd)":/src -w /src -e GITHUB_REPOSITORY -e GITHUB_REPOSITORY_OWNER mcr.microsoft.com/azterraform make "$1"
else
make "$1"
fi

0 comments on commit e2e62f5

Please sign in to comment.