Skip to content

Commit

Permalink
ci-e2e: Updates
Browse files Browse the repository at this point in the history
  • Loading branch information
mikenairn committed Mar 10, 2024
1 parent 41b0b49 commit 2bd3dbc
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
17 changes: 10 additions & 7 deletions .github/workflows/ci-e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ on:
- 'LICENSE'
workflow_dispatch:

env:
TEST_NAMESPACE: e2e-test

jobs:
e2e_test_suite:
name: E2E Test Suite
Expand All @@ -38,27 +41,27 @@ jobs:
cache: false
- name: Create AWS provider configuration
run: |
make local-setup-aws-mz-clean local-setup-aws-mz-generate AWS_ZONE_ROOT_DOMAIN=${{ secrets.E2E_AWS_DNS_PUBLIC_ZONE_NAME }} AWS_DNS_PUBLIC_ZONE_ID=${{ secrets.E2E_AWS_DNS_PUBLIC_ZONE_ID }} AWS_ACCESS_KEY_ID=${{ secrets.E2E_AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY=${{ secrets.E2E_AWS_SECRET_ACCESS_KEY }}
make local-setup-aws-mz-clean local-setup-aws-mz-generate AWS_ZONE_ROOT_DOMAIN=e2e.hcpapps.net AWS_DNS_PUBLIC_ZONE_ID=Z086929132US3PB46EOLR AWS_ACCESS_KEY_ID=${{ secrets.E2E_AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY=${{ secrets.E2E_AWS_SECRET_ACCESS_KEY }}
- name: Create GCP provider configuration
run: |
secret="${{ secrets.E2E_GOOGLE }}"
decoded=$(echo "$secret" | base64 --decode )
make local-setup-gcp-mz-clean local-setup-gcp-mz-generate GCP_ZONE_NAME=${{ secrets.E2E_GCP_ZONE_NAME }} GCP_ZONE_DNS_NAME=${{ secrets.E2E_GCP_ZONE_DNS_NAME }} GCP_GOOGLE='$decoded' GCP_PROJECT_ID=${{ secrets.E2E_PROJECT_ID }}
make local-setup-gcp-mz-clean local-setup-gcp-mz-generate GCP_ZONE_NAME=e2e-google-hcpapps-net GCP_ZONE_DNS_NAME=e2e.google.hcpapps.net GCP_GOOGLE='${{ secrets.E2E_GOOGLE_CREDENTIALS }}' GCP_PROJECT_ID=${{ secrets.E2E_PROJECT_ID }}
- name: Setup environment
run: |
make local-setup DEPLOY=true
make local-setup DEPLOY=true TEST_NAMESPACE=${{ env.TEST_NAMESPACE }}
kubectl -n ${{ env.TEST_NAMESPACE }} wait --timeout=60s --for=condition=Ready managedzone/dev-mz-aws
kubectl -n ${{ env.TEST_NAMESPACE }} wait --timeout=60s --for=condition=Ready managedzone/dev-mz-gcp
- name: Run suite AWS
run: |
export TEST_DNS_MANAGED_ZONE_NAME=dev-mz-aws
export TEST_DNS_ZONE_DOMAIN_NAME=e2e.hcpapps.net
export TEST_NAMESPACE=dnstest
export TEST_DNS_NAMESPACE=${{ env.TEST_NAMESPACE }}
export TEST_DNS_PROVIDER=aws
make test-e2e
- name: Run suite GCP
run: |
export TEST_DNS_MANAGED_ZONE_NAME=dev-mz-gcp
export TEST_DNS_ZONE_DOMAIN_NAME=e2e.google.hcpapps.net
export TEST_NAMESPACE=dnstest
export TEST_DNS_NAMESPACE=${{ env.TEST_NAMESPACE }}
export TEST_DNS_PROVIDER=gcp
make test-e2e
- name: Dump Controller logs
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ build: manifests generate fmt vet ## Build manager binary.

.PHONY: run
run: manifests generate fmt vet ## Run a controller from your host.
go run ./cmd/main.go
go run ./cmd/main.go --zap-log-level=3

# If you wish built the manager image targeting other platforms you can use the --platform flag.
# (i.e. docker build --platform linux/arm64 ). However, you must enable docker buildKit for it.
Expand Down

0 comments on commit 2bd3dbc

Please sign in to comment.