Skip to content

Commit 3e79cdb

Browse files
authored
fix(docker): ensure ssh is set up for private git repos (#844)
1 parent a57d6f5 commit 3e79cdb

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed

orbs/shared/jobs/docker_amd64.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ parameters:
88
description: Space-separated list of registries to push the Docker image to.
99
default: ""
1010
steps:
11+
- add_ssh_keys
1112
- setup_docker_auth:
1213
push_registries: << parameters.push_registries >>
1314
- build_docker_image

orbs/shared/jobs/docker_arm64.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ parameters:
88
description: Space-separated list of registries to push the Docker image to.
99
default: ""
1010
steps:
11+
- add_ssh_keys
1112
- setup_docker_auth:
1213
push_registries: << parameters.push_registries >>
1314
- build_docker_image:

shell/ci/release/docker-authn.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,10 @@ info "🔓 Authenticating to GitHub"
2828
# In order to get the box config, we need to authenticate with GitHub
2929
# shellcheck source=../auth/github.sh
3030
source "${AUTH_DIR}/github.sh"
31+
# We need to set up SSH to ensure that we can access private
32+
# repositories when building the Docker images
33+
# shellcheck source=../auth/ssh.sh
34+
source "${AUTH_DIR}/ssh.sh"
3135

3236
git config --global --remove-section url."ssh://[email protected]"
3337
GH_NO_UPDATE_NOTIFIER=true gh auth setup-git

0 commit comments

Comments
 (0)