[BUG] data github_repository: Owner not being respected when authenticated user belongs to a different organization #1686
Labels
hacktoberfest
Issues for participation in Hacktoberfest
Status: Up for grabs
Issues that are ready to be worked on by anyone
Type: Bug
Something isn't working as documented
Use Case/Problem
We are scaffolding alerts in New Relic where the best source of truth for some required data are yaml files stored within this repository: https://github.com/newrelic/entity-definitions. We are attempting to use the terraform github provider to pull this data directly from where New Relic commits it, and then consume it into our own Terraform via
yamldecode()
. Our Github service user for terraform processes belongs to our company's Github Enterprise organization. The repository we need to read from belongs to New Relic's organization. Currently the provider will not retrieve the data when authenticated with our service user's token. I believe that this is due to the provider searching within our company's GHE tenant for the target repository.Scenario
Github provider is passed a
token
parameter from a user belonging to organization 'xcompany'.Github provider is passed a
base_url
ofghe.xcompany.com
Github provider is passed an
owner
parameter of 'newrelic'Terraform is trying to use a
github_repository
orgithub_repository_file
data source targeting a repository belonging to organization 'newrelic'Terraform configuration
provider.tf
data.tf
outputs.tf
terraform plan ...
I've tried:
data.github_repository_file.infra_awslambdafunction_golden_metrics
owner
from provider.tf and specifying thefull_name
of the repositoryThe text was updated successfully, but these errors were encountered: