File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ FROM alpine AS base
44# On ephemeral containers, the cache is not useful
55ARG BUN_RUNTIME_TRANSPILER_CACHE_PATH=0
66ENV BUN_RUNTIME_TRANSPILER_CACHE_PATH=${BUN_RUNTIME_TRANSPILER_CACHE_PATH}
7- RUN apk add libgcc libstdc++ ripgrep git
7+ RUN apk add libgcc libstdc++ ripgrep git openssh-client
88
99FROM base AS build-amd64
1010COPY dist/shuvcode-linux-x64-baseline-musl/bin/shuvcode /usr/local/bin/shuvcode
@@ -16,5 +16,14 @@ COPY static /usr/local/bin/static
1616
1717ARG TARGETARCH
1818FROM build-${TARGETARCH}
19+
20+ # Create entrypoint script that configures git credentials if GITHUB_TOKEN is set
21+ RUN printf '#!/bin/sh\n \
22+ if [ -n "$GITHUB_TOKEN" ]; then\n \
23+ git config --global credential.helper "!f() { echo username=x-access-token; echo password=$GITHUB_TOKEN; }; f"\n \
24+ git config --global url."https://github.com/".insteadOf "git@github.com:"\n \
25+ fi\n \
26+ exec shuvcode "$@"\n ' > /usr/local/bin/entrypoint.sh && chmod +x /usr/local/bin/entrypoint.sh
27+
1928RUN shuvcode --version
20- ENTRYPOINT ["shuvcode " ]
29+ ENTRYPOINT ["/usr/local/bin/entrypoint.sh " ]
You can’t perform that action at this time.
0 commit comments