Skip to content

Commit

Permalink
Migrate template CI to nava-platform-infra account (#714)
Browse files Browse the repository at this point in the history
  • Loading branch information
lorenyu authored Jul 31, 2024
1 parent e037ced commit 4d6c144
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 6 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/template-only-ci-infra.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ jobs:
# (see https://docs.aws.amazon.com/cli/latest/reference/iam/create-open-id-connect-provider.html)
#
# For this test, use PlatformTestUser20220726 credentials
aws-access-key-id: ${{ secrets.PLATFORM_TESTER_AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.PLATFORM_TESTER_AWS_SECRET_ACCESS_KEY }}
aws-access-key-id: ${{ secrets.TESTER_AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.TESTER_AWS_SECRET_ACCESS_KEY }}

- name: Run Terratest
run: make -f template-only.mak test
Expand Down
4 changes: 2 additions & 2 deletions template-only-test/template_infra_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ func TestEndToEnd(t *testing.T) {

func ValidateAccount(t *testing.T) {
projectName := projectName
accountId := "368823044688"
accountId := "533267424629"
region := "us-east-1"
ValidateAccountBackend(t, region, projectName)
ValidateGithubActionsAuth(t, accountId, projectName)
Expand Down Expand Up @@ -131,7 +131,7 @@ func SetUpDevEnvironment(t *testing.T) {

func ValidateAccountBackend(t *testing.T, region string, projectName string) {
fmt.Println("::group::Validating terraform backend for account")
expectedTfStateBucket := fmt.Sprintf("%s-368823044688-%s-tf", projectName, region)
expectedTfStateBucket := fmt.Sprintf("%s-533267424629-%s-tf", projectName, region)
expectedTfStateKey := "infra/account.tfstate"
aws.AssertS3BucketExists(t, region, expectedTfStateBucket)
_, err := aws.GetS3ObjectContentsE(t, region, expectedTfStateBucket, expectedTfStateKey)
Expand Down
2 changes: 0 additions & 2 deletions template-only.mak
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
PROJECT_NAME ?= platform-template-infra
PROJECT_OWNER ?= platform-admins
PROJECT_REGION ?= us-east-1
ACCOUNT ?= account
ACCOUNT_ID ?= 368823044688

.PHONY : \
clean \
Expand Down

0 comments on commit 4d6c144

Please sign in to comment.