Merge pull request #39 from chris-kruining/fix/session-secret

move the session secret to GH secret
This commit is contained in:
Chris Kruining 2025-03-05 16:04:41 +01:00 committed by GitHub
commit 12492849df
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

View file

@ -49,6 +49,7 @@ jobs:
- name: Build container images - name: Build container images
run: | run: |
echo 'SESSION_SECRET=${{ secrets.SESSION_PASSWORD }}' > .env
docker build . --file Dockerfile --tag ${{ secrets.ACR_LOGIN_SERVER }}/$IMAGE_NAME:${{needs.versionize.outputs.semver}} docker build . --file Dockerfile --tag ${{ secrets.ACR_LOGIN_SERVER }}/$IMAGE_NAME:${{needs.versionize.outputs.semver}}
docker build . --file Dockerfile --tag ${{ secrets.ACR_LOGIN_SERVER }}/$IMAGE_NAME:latest docker build . --file Dockerfile --tag ${{ secrets.ACR_LOGIN_SERVER }}/$IMAGE_NAME:latest

View file

@ -13,7 +13,7 @@ RUN cd /temp/prod && bun install --frozen-lockfile --production
FROM base AS prerelease FROM base AS prerelease
COPY --from=install /temp/dev/node_modules node_modules COPY --from=install /temp/dev/node_modules node_modules
COPY . . COPY . .
RUN echo "SESSION_SECRET=$(head -c 64 /dev/random | base64)" > .env # RUN echo "SESSION_SECRET=$(head -c 64 /dev/random | base64)" > .env
ENV NODE_ENV=production ENV NODE_ENV=production
ENV SERVER_PRESET=bun ENV SERVER_PRESET=bun