-
Notifications
You must be signed in to change notification settings - Fork 2
37 lines (35 loc) · 1.5 KB
/
deploy_prod.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: Deploy prod
on:
push:
branches:
- master
jobs:
deploy-prod:
runs-on: ubuntu-latest
steps:
- name: Set current date to be accessible later with steps.date.outputs.date
id: date
run: echo "::set-output name=date::$(TZ='Europe/Helsinki' date +'%d.%m.%Y_%H:%M')"
- uses: actions/checkout@v4
with:
ref: master
- name: Build UI and publish prod Docker image
uses: elgohr/Publish-Docker-Github-Action@v5
with:
name: hsldevcom/jore-map-ui
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }}
buildargs: APP_ENVIRONMENT=prod, APP_REACT_APP_DIGITRANSIT_API_KEY=${{ secrets.JOREMAPUI_DIGITRANSITAPIKEY_PROD }}, APP_DOMAIN=${{ secrets.APP_DOMAIN_PROD }}, APP_BUILD_DATE=${{ steps.date.outputs.date }}
tags: production
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Build UI and publish stage Docker image
uses: elgohr/Publish-Docker-Github-Action@v5
with:
name: hsldevcom/jore-map-ui
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_ACCESS_TOKEN }}
buildargs: APP_ENVIRONMENT=stage, APP_REACT_APP_DIGITRANSIT_API_KEY=${{ secrets.JOREMAPUI_DIGITRANSITAPIKEY_PROD }}, APP_DOMAIN=${{ secrets.APP_DOMAIN_STAGE }}, APP_BUILD_DATE=${{ steps.date.outputs.date }}
tags: stage
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}