• R/O
  • HTTP
  • SSH
  • HTTPS

提交

标签
No Tags

Frequently used words (click to add to your profile)

javaandroidc++linuxc#objective-ccocoa誰得qtrubypythongamewindowsbathyscaphephpguic翻訳omegattwitterframeworktestbtronarduinovb.net計画中(planning stage)directxpreviewerゲームエンジンdom

the default GitOps source repository for booting up Jenkins X


Commit MetaInfo

修订版a6cae5494dca418debcf5230b2e1147ba5827bdd (tree)
时间2019-09-13 16:45:36
作者jenkins-x-bot <35031835+jenkins-x-bot@user...>
CommiterGitHub

Log Message

Merge pull request #67 from ccojocar/volumes-for-secrets

fix: set the environment variables directly from secrets instead of using step credential command

更改概述

差异

--- a/bdd/bdd.sh
+++ b/bdd/bdd.sh
@@ -13,9 +13,6 @@ export GH_USERNAME="jenkins-x-bot-test"
1313 export GH_EMAIL="jenkins-x@googlegroups.com"
1414 export GH_OWNER="cb-kubecd"
1515
16-export GH_CREDS_PSW="$(jx step credential -s jenkins-x-bot-test-github)"
17-export JENKINS_CREDS_PSW="$(jx step credential -s test-jenkins-user)"
18-
1916 # fix broken `BUILD_NUMBER` env var
2017 export BUILD_NUMBER="$BUILD_ID"
2118
@@ -37,11 +34,11 @@ git config --global --add user.email jenkins-x@googlegroups.com
3734 echo "running the BDD tests with JX_HOME = $JX_HOME"
3835
3936 # setup jx boot parameters
40-export JX_VALUE_ADMINUSER_PASSWORD="$JENKINS_CREDS_PSW"
37+export JX_VALUE_ADMINUSER_PASSWORD="$JENKINS_PASSWORD"
4138 export JX_VALUE_PIPELINEUSER_USERNAME="$GH_USERNAME"
4239 export JX_VALUE_PIPELINEUSER_EMAIL="$GH_EMAIL"
43-export JX_VALUE_PIPELINEUSER_TOKEN="$GH_CREDS_PSW"
44-export JX_VALUE_PROW_HMACTOKEN="$GH_CREDS_PSW"
40+export JX_VALUE_PIPELINEUSER_TOKEN="$GH_ACCESS_TOKEN"
41+export JX_VALUE_PROW_HMACTOKEN="$GH_ACCESS_TOKEN"
4542
4643 # TODO temporary hack until the batch mode in jx is fixed...
4744 export JX_BATCH_MODE="true"
@@ -79,8 +76,8 @@ jx step bdd \
7976 --git-provider=github \
8077 --git-username $GH_USERNAME \
8178 --git-owner $GH_OWNER \
82- --git-api-token $GH_CREDS_PSW \
83- --default-admin-password $JENKINS_CREDS_PSW \
79+ --git-api-token $GH_ACCESS_TOKEN \
80+ --default-admin-password $JENKINS_PASSWORD \
8481 --no-delete-app \
8582 --no-delete-repo \
8683 --tests install \
--- a/jenkins-x-bdd-local.yml
+++ b/jenkins-x-bdd-local.yml
@@ -19,6 +19,16 @@ pipelineConfig:
1919 value: /secrets/bdd/sa.json
2020 - name: DOMAIN_ROTATION
2121 value: "false"
22+ - name: GH_ACCESS_TOKEN
23+ valueFrom:
24+ secretKeyRef:
25+ name: jenkins-x-bot-test-github
26+ key: password
27+ - name: JENKINS_PASSWORD
28+ valueFrom:
29+ secretKeyRef:
30+ name: test-jenkins-user
31+ key: password
2232 agent:
2333 image: gcr.io/jenkinsxio/builder-go-maven
2434 stages:
--- a/jenkins-x-bdd-vault.yml
+++ b/jenkins-x-bdd-vault.yml
@@ -23,6 +23,16 @@ pipelineConfig:
2323 value: ".bdd.jenkins-x.rocks"
2424 - name: GKE_SA
2525 value: /secrets/bdd/sa.json
26+ - name: GH_ACCESS_TOKEN
27+ valueFrom:
28+ secretKeyRef:
29+ name: jenkins-x-bot-test-github
30+ key: password
31+ - name: JENKINS_PASSWORD
32+ valueFrom:
33+ secretKeyRef:
34+ name: test-jenkins-user
35+ key: password
2636 agent:
2737 image: gcr.io/jenkinsxio/builder-go-maven
2838 stages: