Browse Source

insert environment name in argocd commands

pull/79/head
Megha Mehta 4 years ago
committed by GitHub
parent
commit
ab3e277d3a
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 10
      Jenkinsfile

10
Jenkinsfile

@ -23,14 +23,14 @@ node {
stage('Create app') { stage('Create app') {
withKubeConfig(credentialsId: 'aws-eksctl-kubeconfig', serverUrl: '') { withKubeConfig(credentialsId: 'aws-eksctl-kubeconfig', serverUrl: '') {
sh """ sh """
argocd app create prod-kustomize-guestbook \ argocd app create ${env.BRANCHNAME}-kustomize-guestbook \
--repo https://github.com/radtac-craft/argocd-example-apps.git \ --repo https://github.com/radtac-craft/argocd-example-apps.git \
--path kustomize-guestbook/overlays/prod \ --path kustomize-guestbook/overlays/${env.BRANCHNAME} \
--dest-server https://kubernetes.default.svc \ --dest-server https://kubernetes.default.svc \
--dest-namespace prod-kustomize-guestbook --dest-namespace ${env.BRANCHNAME}-kustomize-guestbook
""" """
sh 'argocd app sync prod-kustomize-guestbook' sh 'argocd app sync ${env.BRANCHNAME}-kustomize-guestbook'
sh 'argocd app wait prod-kustomize-guestbook --sync' sh 'argocd app wait ${env.BRANCHNAME}-kustomize-guestbook --sync'
} }
} }

Loading…
Cancel
Save