This repository was archived by the owner on Jun 30, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +39
-32
lines changed Expand file tree Collapse file tree 3 files changed +39
-32
lines changed Original file line number Diff line number Diff line change 1+ on : [push, pull_request]
2+
3+ env :
4+ IMAGE_NAME : restbase
5+
6+ jobs :
7+ docker_image_job :
8+ runs-on : ubuntu-latest
9+ steps :
10+ # don't need to use the actions/checkout when using setup-buildx-action
11+
12+ - name : Set up QEMU
13+ uses : docker/setup-qemu-action@v1
14+
15+ - name : Set up Docker Buildx
16+ uses : docker/setup-buildx-action@v1
17+
18+ - name : Login to GitHub Container Registry
19+ if : github.repository_owner == 'femiwiki'
20+ uses : docker/login-action@v1
21+ with :
22+ registry : ghcr.io
23+ username : ${{ github.repository_owner }}
24+ password : ${{ secrets.GITHUB_TOKEN }}
25+
26+ - id : version
27+ run : echo "::set-output name=version::$(date +%Y-%m-%dT%H-%M)-$(echo ${{ github.sha }} | cut -c1-8)"
28+
29+ - name : Build and push
30+ id : docker_build
31+ uses : docker/build-push-action@v2
32+ with :
33+ cache-from : ghcr.io/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:latest
34+ platforms : linux/amd64,linux/arm64
35+ push : ${{ github.repository_owner == 'femiwiki' && github.ref == 'refs/heads/main' }}
36+ tags : |
37+ ghcr.io/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:${{ steps.version.outputs.version }}
38+ ghcr.io/${{ github.repository_owner }}/${{ env.IMAGE_NAME }}:latest
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 1- FROM node:10-alpine
1+ FROM --platform=$TARGETPLATFORM node:10-alpine
22
33ARG NODE_ENV=production
44# Environment variables used by RESTBase
You can’t perform that action at this time.
0 commit comments