From c2e526ca57bce323537f64c682bf9982502abd44 Mon Sep 17 00:00:00 2001 From: Sunny Date: Thu, 31 Aug 2023 14:50:47 +0000 Subject: [PATCH] workflows/e2e-gcp: Fix secret variable typo Also update terraform config to add a description to the service account and a note about github organization repo. Signed-off-by: Sunny --- .github/workflows/e2e-gcp.yaml | 4 ++-- tests/integration/README.md | 9 +++++++-- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/e2e-gcp.yaml b/.github/workflows/e2e-gcp.yaml index 99d7be26..5f68c639 100644 --- a/.github/workflows/e2e-gcp.yaml +++ b/.github/workflows/e2e-gcp.yaml @@ -76,8 +76,8 @@ jobs: TF_VAR_gcp_region: ${{ vars.TF_VAR_gcp_region }} TF_VAR_gcp_zone: ${{ vars.TF_VAR_gcp_zone }} TF_VAR_gcp_email: ${{ secrets.TF_VAR_gcp_email }} - TF_VAR_gcp_keyring: ${{ secret.TF_VAR_gcp_keyring }} - TF_VAR_gcp_crypto_key: ${{ secret.TF_VAR_gcp_crypto_key }} + TF_VAR_gcp_keyring: ${{ secrets.TF_VAR_gcp_keyring }} + TF_VAR_gcp_crypto_key: ${{ secrets.TF_VAR_gcp_crypto_key }} GITREPO_SSH_CONTENTS: ${{ secrets.GCP_GITREPO_SSH_CONTENTS }} GITREPO_SSH_PUB_CONTENTS: ${{ secrets.GCP_GITREPO_SSH_PUB_CONTENTS }} run: | diff --git a/tests/integration/README.md b/tests/integration/README.md index 01c331b8..db6f8d14 100644 --- a/tests/integration/README.md +++ b/tests/integration/README.md @@ -218,6 +218,10 @@ variables using use the terraform configuration below. Please make sure all the requirements of gcp-gh-actions are followed before running it. +**NOTE:** When running the following for a repo under and organization, set the +environment variable `GITHUB_ORGANIZATION` if setting the `owner` in the +`github` provider doesn't work. + ```hcl provider "google" {} @@ -233,8 +237,9 @@ resource "tls_private_key" "privatekey" { module "gcp_gh_actions" { source = "git::https://github.com/fluxcd/test-infra.git//tf-modules/gcp/github-actions" - gcp_service_account_id = "flux2-e2e-test" - gcp_service_account_name = "flux2-e2e-test" + gcp_service_account_id = "flux2-e2e-test" + gcp_service_account_name = "flux2-e2e-test" + gcp_service_account_description = "For running fluxcd/flux2 e2e tests." gcp_roles = [ "roles/compute.instanceAdmin.v1", "roles/container.admin",