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

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

Commit message

Mount .ssh folder to docker instance.

We need to mount .ssh folder to docker instance so that git can
establish the ssh connection to access the private repo.

Description of the change

Mount .ssh folder to docker instance.

We need to mount .ssh folder to docker instance so that git can
establish the ssh connection to access the private repo.

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 95fa694..97c7697 100644
3--- a/jobs/snap/snap-test.sh
4+++ b/jobs/snap/snap-test.sh
5@@ -83,7 +83,7 @@ go build github.com/snapcore/spread/cmd/spread
6 mkdir /build/bin
7 cp spread /build/bin
8
9-git clone --depth 1 -b $CI_BRANCH git+ssh://$BOT_USERNAME@git.launchpad.net/~$LAUNCHPAD_TEAM/$LAUNCHPAD_PROJECT/+git/$CI_REPO /build/src
10+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
11 cd /build/src
12
13 # Copy any stage results from previous generic-build-snap-worker builds
14@@ -117,6 +117,7 @@ $SSH time sudo docker run \
15 --rm \
16 -v /dev:/dev \
17 -v $REMOTE_WORKSPACE:/build \
18+ -v $JENKINS_HOME/.ssh:/root/.ssh \
19 --privileged \
20 snap-spread-tests /build/run-tests.sh
21

Subscribers

People subscribed via source and target branches

to all changes: