Merge ~gary-wzl77/snappy-hwe-snaps/+git/jenkins-jobs:key_path into ~snappy-hwe-team/snappy-hwe-snaps/+git/jenkins-jobs:master

Proposed by Gary.Wang
Status: Merged
Approved by: Simon Fels
Approved revision: 2e18c580e524392c468d4040b4a09b8699929c80
Merged at revision: 009c9ada1ace1fc134fc8f580312d9808ade4b74
Proposed branch: ~gary-wzl77/snappy-hwe-snaps/+git/jenkins-jobs:key_path
Merge into: ~snappy-hwe-team/snappy-hwe-snaps/+git/jenkins-jobs:master
Diff against target: 23 lines (+3/-2)
1 file modified
jobs/snap/snap-test.sh (+3/-2)
Reviewer Review Type Date Requested Status
Simon Fels Approve
System Enablement Bot continuous-integration Approve
Review via email: mp+334738@code.launchpad.net

Commit message

Fix the ci bot key path.

The ci bot key is placed in one specific folder, not the default
and global one. We need to declare the exact key path in GIT_SSH_COMMAND
variable to avoid 'No such file or directory' error.

Description of the change

Fix the ci bot key path.

The ci bot key is placed in one specific folder, not the default
and global one. We need to declare the exact key path in GIT_SSH_COMMAND
variable to avoid 'No such file or directory' error.

To post a comment you must log in.
Revision history for this message
System Enablement Bot (system-enablement-ci-bot) wrote :
review: Approve (continuous-integration)
Revision history for this message
Simon Fels (morphis) wrote :

LGTM

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/jobs/snap/snap-test.sh b/jobs/snap/snap-test.sh
2index 97c7697..8b679f9 100644
3--- a/jobs/snap/snap-test.sh
4+++ b/jobs/snap/snap-test.sh
5@@ -29,7 +29,8 @@ if [ "$RUN_TESTS" = False ]; then
6 fi
7
8 SSH_PATH="${JENKINS_HOME}/.ssh/"
9-SSH_KEY_PATH="${SSH_PATH}/git.launchpad.net/system-enablement-ci-bot"
10+CI_BOT_KEY_PATH="git.launchpad.net/system-enablement-ci-bot"
11+SSH_KEY_PATH="${SSH_PATH}/${CI_BOT_KEY_PATH}"
12
13 SSH="ssh -i $SSH_KEY_PATH/id_rsa $REMOTE_USER@$REMOTE_WORKER"
14 SCP="scp -i $SSH_KEY_PATH/id_rsa"
15@@ -83,7 +84,7 @@ go build github.com/snapcore/spread/cmd/spread
16 mkdir /build/bin
17 cp spread /build/bin
18
19-GIT_SSH_COMMAND='ssh -i /root/.ssh/id_rsa' git clone --depth 1 -b $CI_BRANCH git+ssh://$BOT_USERNAME@git.launchpad.net/~$LAUNCHPAD_TEAM/$LAUNCHPAD_PROJECT/+git/$CI_REPO /build/src
20+GIT_SSH_COMMAND='ssh -i /root/.ssh/$CI_BOT_KEY_PATH/id_rsa' git clone --depth 1 -b $CI_BRANCH git+ssh://$BOT_USERNAME@git.launchpad.net/~$LAUNCHPAD_TEAM/$LAUNCHPAD_PROJECT/+git/$CI_REPO /build/src
21 cd /build/src
22
23 # Copy any stage results from previous generic-build-snap-worker builds

Subscribers

People subscribed via source and target branches

to all changes: