Azure / alz-terraform-accelerator

Azure Landing Zones Terraform Accelerator
MIT License
98 stars 32 forks source link

bug: Main GitHub repository doesn't have access to the pipeline template repository #124

Closed GraemeMeyerGT closed 5 months ago

GraemeMeyerGT commented 6 months ago

Is there an existing issue for this?

Bootstrap or Starter Module Deployment? (Required)

bootstrap

ALZ-PowerShell-Module Version (Required)

2.0.2

alz-terraform-accelerator Version (Required)

1.0.3

Starter Module (Required)

Basic

Input arguments of the ALZ-PowerShell-Module (Required)

`New-ALZEnvironment -iac "terraform" -c "github"`

Expected Behaviour (Required)

The main pipelines should be ready to run, without having to manually grant access to the pipelines in the template repository.

Actual Behaviour (Required)

It looks like the bootstrap doesn't grant the main repo access to the template repository, which is required to run the pipelines in the main repo:

[Invalid workflow file: .github/workflows/ci.yaml#L11](https://github.com/REDACTED-ORG-NAME/alz-mgmt/actions/runs/8470468009/workflow)
error parsing called workflow
".github/workflows/ci.yaml"
-> "REDACTED-ORG-NAME/alz-mgmt-templates/.github/workflows/ci_template.yaml@main"
: workflow was not found. See https://docs.github.com/actions/learn-github-actions/reusing-workflows#access-to-reusable-workflows for more information.

Flipping this switch - granting repo access - does allow the CI pipeline in the main repo to proceed:

image

References (Optional)

https://docs.github.com/en/actions/using-workflows/reusing-workflows#access-to-reusable-workflows

jaredfholgate commented 5 months ago

Apologies for just getting to this. I spotted this issue myself when testing with an Enterprise licensed org earlier this week and submitted a fix which has not been released.