You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Portfolio/.github/workflows/build.yml

54 lines
1.1 KiB

name: deploy
on:
push:
branches:
- main
jobs:
typescript:
runs-on: ubuntu-latest
steps:
- name: Setup checkout
uses: actions/checkout@v2
- name: Setup NodeJS v12
uses: actions/setup-node@v1
with:
node-version: 16
- name: Install Dependencies
run: yarn install
- name: Check for syntax errors
run: yarn test-build
- name: ESlint check
run: yarn lint
docker:
runs-on: ubuntu-latest
needs: typescript
steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Login to DockerHub
uses: docker/login-action@v1
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build Dockerfile and push
id: docker_build
uses: docker/build-push-action@v2
with:
push: true
tags: guusvanmeerveld/portfolio:latest
- name: Image digest
run: echo ${{ steps.docker_build.outputs.digest }}