diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 72c8f8e..4ab9367 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -1,3 +1,3 @@ # AVM core team owns key files -.github/policies/ @Azure/avm-core-team-technical -.github/CODEOWNERS @Azure/avm-core-team-technical +.github/policies/ @Azure/avm-core-team-technical-terraform +.github/CODEOWNERS @Azure/avm-core-team-technical-terraform diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index 9bfb58d..c14c3ea 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -18,7 +18,7 @@ jobs: outputs: examples: ${{ steps.getexamples.outputs.examples }} steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 #v4.1.2 + - uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 #v4.1.6 - name: get examples id: getexamples uses: Azure/terraform-azurerm-avm-template/.github/actions/e2e-getexamples@main @@ -38,7 +38,7 @@ jobs: example: ${{ fromJson(needs.getexamples.outputs.examples) }} fail-fast: false steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 #v4.1.2 + - uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 #v4.1.6 - name: Test example shell: bash diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml index 95aa5f4..ea8667e 100644 --- a/.github/workflows/linting.yml +++ b/.github/workflows/linting.yml @@ -21,7 +21,7 @@ jobs: runs-on: ubuntu-latest steps: - name: checkout repository - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 #v4.1.2 + uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 #v4.1.6 - name: check docs uses: Azure/terraform-azurerm-avm-template/.github/actions/docs-check@main @@ -32,7 +32,7 @@ jobs: runs-on: ubuntu-latest steps: - name: checkout repository - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 #v4.1.2 + uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 #v4.1.6 - name: lint terraform uses: Azure/terraform-azurerm-avm-template/.github/actions/linting@main @@ -40,12 +40,18 @@ jobs: github-token: ${{ secrets.GITHUB_TOKEN }} avmfix: - if: github.event.repository.name != 'terraform-azurerm-avm-template' && false + if: github.event.repository.name != 'terraform-azurerm-avm-template' name: avmfix runs-on: ubuntu-latest steps: - name: checkout repository - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 #v4.1.2 + uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 #v4.1.6 - name: avmfix uses: Azure/terraform-azurerm-avm-template/.github/actions/avmfix@main + + lintcomplete: + needs: [docs, terraform, avmfix] + runs-on: ubuntu-latest + steps: + - run: echo "All linting checks passed" diff --git a/.github/workflows/version-check.yml b/.github/workflows/version-check.yml index 8e3e0fd..d0df1cc 100644 --- a/.github/workflows/version-check.yml +++ b/.github/workflows/version-check.yml @@ -16,7 +16,7 @@ jobs: if: github.event.repository.name != 'terraform-azurerm-avm-template' runs-on: ubuntu-latest steps: - - uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 #v4.1.2 + - uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 #v4.1.6 - name: Check version uses: Azure/terraform-azurerm-avm-template/.github/actions/version-check@main with: diff --git a/avm b/avm index 69f9ce0..6668be7 100755 --- a/avm +++ b/avm @@ -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