Skip to content

Update build_push.yml #20

Update build_push.yml

Update build_push.yml #20

Workflow file for this run

name: Build and Docker Push
on:
push:
branches:
- develop
jobs:
build-deploy:
runs-on: ubuntu-latest
env:
REACT_APP_BASE_URL: ${{ secrets.REACT_APP_BASE_URL }}
REACT_APP_KAKAO_JS_KEY: ${{ secrets.REACT_APP_KAKAO_JS_KEY }}
REACT_APP_KAKAO_REST_API_KEY: ${{ secrets.REACT_APP_KAKAO_REST_API_KEY }}
REACT_APP_GOOGLE_ANALYTICS: ${{ secrets.REACT_APP_GOOGLE_ANALYTICS }}
REACT_APP_GOOGLE_TAG: ${{ secrets.REACT_APP_GOOGLE_TAG }}
steps:
- name: Checkout repository
uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: '18'
- name: Install dependencies
run: yarn install
- name: Build project
run: yarn build
- name: Login to Docker Hub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and Push Docker Image
run: |
docker build -t royroyee/todays-menu-frontend:latest .
docker push royroyee/todays-menu-frontend:latest