Skip to content

Commit

Permalink
Merge pull request #493 from stakater-lab/parameterize
Browse files Browse the repository at this point in the history
parameterize and put back secret
  • Loading branch information
AsfaMumtaz authored Oct 25, 2023
2 parents 9d18e8e + 421c05c commit 5e6df1d
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 10 deletions.
11 changes: 8 additions & 3 deletions .tekton/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,18 @@ spec:
value: stakater-lab
- name: tenant
value: psg
- name: route_subdomain
value: apps.tno1-ams.s9nghh76.lab.kubeapp.cloud
pipelineSpec:
params:
- name: repo_url
- name: git_revision
- name: repo_path
- name: image_registry
- name: helm_registry
- name: organization
- name: tenant
- name: route_subdomain
workspaces:
- name: source
- name: ssh-directory
Expand Down Expand Up @@ -131,7 +136,7 @@ spec:
kind: Task
params:
- name: SONAR_HOST_URL
value: https://sonarqube-stakater-sonarqube.apps.tno1-ams.s9nghh76.lab.kubeapp.cloud
value: https://sonarqube-stakater-sonarqube.$(params.route_subdomain)

- name: SONAR_PROJECT_KEY
value: $(params.repo_path)
Expand Down Expand Up @@ -227,13 +232,13 @@ spec:
- name: GIT_REVISION
value: main
- name: NAMESPACE
value: psg-dev
value: $(params.tenant)-dev
- name: ENVIRONMENT
value: 01-dev
- name: HELM_REGISTRY
value: $(params.helm_registry)
- name: CD_REPO_URL
value: [email protected]:stakater/nordmart-apps-gitops-config.git
value: [email protected]:$(params.organization)/nordmart-apps-gitops-config.git
workspaces:
- name: source
workspace: source
Expand Down
17 changes: 11 additions & 6 deletions .tekton/pull_request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ spec:
https://nexus-helm-stakater-nexus.apps.tno1-ams.s9nghh76.lab.kubeapp.cloud/repository/helm-charts/
- name: organization
value: stakater-lab
- name: tenant
value: psg
- name: route_subdomain
value: apps.tno1-ams.s9nghh76.lab.kubeapp.cloud
pipelineSpec:
params:
- name: repo_url
Expand All @@ -53,6 +57,7 @@ spec:
- name: pull_request_number
- name: organization
- name: git_branch
- name: tenant

workspaces:
- name: source
Expand Down Expand Up @@ -107,15 +112,15 @@ spec:
- name: PR_NUMBER
value: $(params.pull_request_number)
- name: GIT_URL
value: https://github.com/stakater-lab/stakater-nordmart-review-api.git
value: https://github.com/$(params.organization)/stakater-nordmart-review-api.git
- name: GIT_BRANCH
value: $(params.git_branch)
- name: IMAGE_TAG
value: $(tasks.create-git-tag.results.GIT_TAG)
- name: IMAGE_REPO
value: $(params.image_registry)
- name: PULL_REQUEST_COMMITS_API
value: https://api.github.com/repos/stakater-lab/$(params.repo_path)/pulls/$(params.pull_request_number)/commits
value: https://api.github.com/repos/$(params.organization)/$(params.repo_path)/pulls/$(params.pull_request_number)/commits
workspaces:
- name: output
workspace: source
Expand All @@ -142,7 +147,7 @@ spec:
- name: DEPLOYMENT_FILES_PATH
value: deploy
- name: NAMESPACE
value: psg-build
value: $(params.tenant)-build
workspaces:
- name: source
workspace: source
Expand All @@ -166,7 +171,7 @@ spec:
kind: Task
params:
- name: SONAR_HOST_URL
value: https://sonarqube-stakater-sonarqube.apps.tno1-ams.s9nghh76.lab.kubeapp.cloud
value: https://sonarqube-stakater-sonarqube.$(params.route_subdomain)
- name: SONAR_PROJECT_KEY
value: $(params.repo_path)
- name: SONAR_LOGIN
Expand Down Expand Up @@ -322,13 +327,13 @@ spec:
- name: GIT_REVISION
value: $(params.git_revision)
- name: NAMESPACE
value: psg-dev
value: $(params.tenant)-dev
- name: ENVIRONMENT
value: dev
- name: HELM_REGISTRY
value: $(params.helm_registry)
- name: CD_REPO_URL
value: [email protected]:stakater/nordmart-apps-gitops-config.git
value: [email protected]:$(params.organization)/nordmart-apps-gitops-config.git
workspaces:
- name: source
workspace: source
Expand Down
6 changes: 5 additions & 1 deletion deploy/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ application:
pattern: "(ERROR|ERR|error|E[A-Z0-9]{4})"
additionalLabels:
appCategory: backend
imagePullSecrets: docker-reg-creds
imagePullSecrets: review-docker-reg-creds
env:
MONGODB_PASSWORD:
valueFrom:
Expand Down Expand Up @@ -143,6 +143,10 @@ application:
dataFrom:
key: review-api/dev/mongodb-creds

docker-reg-creds:
dataFrom:
key: docker-reg-creds

#####################
# MongoDB dependency
#####################
Expand Down

0 comments on commit 5e6df1d

Please sign in to comment.