File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -40,12 +40,12 @@ jobs:
4040
4141 - name : Build and push image
4242 uses : docker/build-push-action@v7
43- env :
44- GITHUB_TOKEN : ${{ secrets.GHP_TOKEN }}
4543 with :
4644 context : ./apps/landing-page
4745 file : ./apps/landing-page/Dockerfile
4846 push : true
47+ secrets : |
48+ github_token=${{ secrets.GHP_TOKEN }}
4949 tags : |
5050 ghcr.io/${{ github.repository }}-landing-page:latest
5151 ghcr.io/${{ github.repository }}-landing-page:${{ github.sha }}
Original file line number Diff line number Diff line change @@ -27,9 +27,8 @@ COPY . .
2727# Uncomment the following line in case you want to disable telemetry during the build.
2828ENV NEXT_TELEMETRY_DISABLED=1
2929
30- ENV GITHUB_TOKEN=${GITHUB_TOKEN}
31-
32- RUN \
30+ RUN --mount=type=secret,id=github_token \
31+ export GITHUB_TOKEN=$(cat /run/secrets/github_token) && \
3332 if [ -f yarn.lock ]; then yarn run build; \
3433 elif [ -f package-lock.json ]; then npm run build; \
3534 elif [ -f pnpm-lock.yaml ]; then corepack enable pnpm && pnpm run build; \
You can’t perform that action at this time.
0 commit comments