Skip to content

Commit

Permalink
fix: fixed workflow script
Browse files Browse the repository at this point in the history
  • Loading branch information
anaik91 committed Oct 28, 2023
1 parent 08fbfc7 commit b1c70df
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
9 changes: 6 additions & 3 deletions test/scripts/run_playbook.sh
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,10 @@ replace_string "$ANSIBLE_DIR/vars/test.yaml" "_GCP_PROJECT_ID_" "${GCP_PROJECT_I
replace_string "$ANSIBLE_DIR/vars/test.yaml" "_GCP_REGION_" "${GCP_REGION}"

docker run -v "$ANSIBLE_DIR:/app" \
-v "$GOOGLE_APPLICATION_CREDENTIALS:/app/kubeconfig" \
-e GOOGLE_APPLICATION_CREDENTIALS=/app/kubeconfig \
-v "$GOOGLE_APPLICATION_CREDENTIALS:/svc_account/account.json" \
-e GOOGLE_APPLICATION_CREDENTIALS=/svc_account/account.json \
"$GCP_REGION-docker.pkg.dev/$GCP_PROJECT_ID/$GCP_GAR_REPO/ansible-helm-apigee-hybrid-deployer:$GIT_COMMIT_SHORT_ID" \
/bin/bash -c "cd /app && ansible-playbook playbook.yaml --tags 'dc1' -e @vars/test.yaml"
/bin/bash -c "cd /app && \
gcloud auth login --cred-file=/svc_account/account.json && \
gcloud container clusters get-credentials apigee-hybrid-cicd-test --region $GCP_REGION --project $GCP_PROJECT_ID && \
ansible-playbook playbook.yaml --tags 'dc1' -e @vars/test.yaml"
6 changes: 3 additions & 3 deletions vars/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@

---
# Path to download/generate files
setup_path: "/tmp"
setup_path: "/tmp/setup"

# Set `cert_manager_version: : v1.7.2` refer: https://cloud.google.com/apigee/docs/hybrid/v1.10/install-cert-manager
install_cert_manager: false
install_cert_manager: true
cert_manager_version: v1.7.2

################################################ TLS certificate details ################################################
Expand Down Expand Up @@ -68,7 +68,7 @@ helm_charts:

kubeconfigs:
# set `primary: <Path to kubeconfig of K8s cluster>` to deploy Apigee Hybrid Primary DC
primary: /Users/ashwinknaik/codes/git/apigee-hybrid-ansible/ansible/certs/dc1.config
primary: /root/.kube/config
# set `secondary: <Path to kubeconfig of K8s cluster>` to deploy Apigee Hybrid Secondary DC
# secondary: /tmp/dc2.config

Expand Down

0 comments on commit b1c70df

Please sign in to comment.