mirror of
https://github.com/techno-tim/littlelink-server.git
synced 2024-11-26 06:05:34 +01:00
54 lines
1.3 KiB
YAML
54 lines
1.3 KiB
YAML
name: CI for releases
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
|
|
jobs:
|
|
js-install-and-test:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
node-version: [v14.17.4]
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Use Node.js ${{ matrix.node-version }}
|
|
uses: actions/setup-node@master
|
|
with:
|
|
node-version: ${{ matrix.node-version }}
|
|
- name: Install Dependencies, Test, and Build
|
|
run: |
|
|
yarn install --frozen-lockfile --check-files
|
|
env:
|
|
CI: true
|
|
|
|
build-and-push-docker-image:
|
|
needs: [js-install-and-test]
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
-
|
|
name: Checkout
|
|
uses: actions/checkout@v2
|
|
-
|
|
name: Set up QEMU
|
|
uses: docker/setup-qemu-action@v1
|
|
-
|
|
name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v1
|
|
-
|
|
name: Login to GitHub Container Registry
|
|
uses: docker/login-action@v1
|
|
with:
|
|
registry: ghcr.io
|
|
username: ${{ github.repository_owner }}
|
|
password: ${{ secrets.PAT }}
|
|
-
|
|
name: Build and push
|
|
uses: docker/build-push-action@v2
|
|
with:
|
|
context: .
|
|
file: ./Dockerfile
|
|
platforms: linux/amd64,linux/arm64,linux/arm/v7
|
|
push: true
|
|
tags: ghcr.io/techno-tim/littlelink-server:latest |