Skip to content

Commit

Permalink
AB#33966: Pass api key to client-side in env variables (#407)
Browse files Browse the repository at this point in the history
  • Loading branch information
e-halinen authored Mar 27, 2024
1 parent 77a92fb commit da5eaf4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/buildAndPublish_dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,9 @@ jobs:
context: .
push: true
tags: ${{ format('hsldevcom/hsl-map-publisher:dev-{0}-{1}', steps.timestamp.outputs.timestamp, steps.commit_hash.outputs.hash) }}
build-args: |
build-args:
BUILD_ENV=dev
env:
DIGITRANSIT_APIKEY=${{ secrets.KARTAT_DIGITRANSITAPIKEY_DEV }}

- name: Build and push
Expand All @@ -50,4 +51,5 @@ jobs:
tags: hsldevcom/hsl-map-publisher:dev
build-args: |
BUILD_ENV=dev
env:
DIGITRANSIT_APIKEY=${{ secrets.KARTAT_DIGITRANSITAPIKEY_DEV }}
2 changes: 0 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ COPY . ${WORK}
ARG BUILD_ENV=prod
COPY .env.${BUILD_ENV} ${WORK}/.env

ARG DIGITRANSIT_APIKEY
ENV DIGITRANSIT_APIKEY=${DIGITRANSIT_APIKEY}
ENV BUILD_ENV=${BUILD_ENV}
RUN yarn run build

Expand Down

0 comments on commit da5eaf4

Please sign in to comment.