File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change 60
60
run : |
61
61
git config --global url."git@github.com:".insteadOf "https://github.com/"
62
62
63
+ - name : Verify SSH agent and add GitHub to known hosts
64
+ run : |
65
+ ssh-add -l
66
+ mkdir -p ~/.ssh
67
+ ssh-keyscan github.com >> ~/.ssh/known_hosts
68
+ echo "SSH_AUTH_SOCK=$SSH_AUTH_SOCK" >> $GITHUB_ENV
69
+
63
70
- name : Build and push platform-specific image
64
71
id : build
65
72
uses : docker/build-push-action@263435318d21b8e681c14492fe198d362a7d2c83 # @6.18.0
Original file line number Diff line number Diff line change @@ -9,12 +9,15 @@ RUN cargo chef prepare --recipe-path recipe.json
9
9
FROM chef AS builder
10
10
COPY --from=planner /app/recipe.json recipe.json
11
11
12
+ # Force cargo to use git CLI for SSH
13
+ ENV CARGO_NET_GIT_FETCH_WITH_CLI=true
14
+
12
15
# Build dependencies - this is the caching Docker layer
13
- RUN cargo chef cook --release --recipe-path recipe.json
16
+ RUN --mount=type=ssh cargo chef cook --release --recipe-path recipe.json
14
17
15
18
# Build application
16
19
COPY . .
17
- RUN cargo build --release --bin thirdweb-engine
20
+ RUN --mount=type=ssh cargo build --release --bin thirdweb-engine
18
21
19
22
# Runtime stage
20
23
FROM debian:bookworm-slim AS runtime
You can’t perform that action at this time.
0 commit comments