Update Builder for ARM
This commit is contained in:
30
.github/workflows/release.yml
vendored
30
.github/workflows/release.yml
vendored
@@ -6,12 +6,18 @@ on:
|
|||||||
- main # Set a branch to deploy
|
- main # Set a branch to deploy
|
||||||
|
|
||||||
env:
|
env:
|
||||||
IMAGE_REPO: ghcr.io/hotarublaze
|
IMAGE_REGISTRY: ghcr.io
|
||||||
IMAGE_NAME: fluttershub-blog
|
IMAGE_OWNER: fluttershub
|
||||||
|
IMAGE_NAME: blog
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
deploy:
|
deploy:
|
||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-18.04
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
CPU_ARCH:
|
||||||
|
- arm64
|
||||||
|
- x86_64
|
||||||
# If running with act, Uncomment below
|
# If running with act, Uncomment below
|
||||||
container: phaze9/action-runner
|
container: phaze9/action-runner
|
||||||
steps:
|
steps:
|
||||||
@@ -38,10 +44,22 @@ jobs:
|
|||||||
username: ${{ github.repository_owner }}
|
username: ${{ github.repository_owner }}
|
||||||
password: ${{ secrets.GITHUB_TOKEN }}
|
password: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- name: Build and push
|
- name: Build and push - x64
|
||||||
id: docker_build
|
id: docker_build_x64
|
||||||
uses: docker/build-push-action@v2
|
uses: docker/build-push-action@v2
|
||||||
|
if: ${{ matrix.CPU_ARCH == 'x86_64'}}
|
||||||
with:
|
with:
|
||||||
push: true
|
push: true
|
||||||
platforms: linux/amd64,linux/arm64
|
platforms: linux/amd64
|
||||||
tags: ${{ env.IMAGE_REPO }}/${{ env.IMAGE_NAME }}:latest
|
labels: org.opencontainers.image.source https://github.com/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}
|
||||||
|
tags: ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:x64-latest
|
||||||
|
|
||||||
|
- name: Build and push - arm64
|
||||||
|
id: docker_build_arm64
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
if: ${{ matrix.CPU_ARCH == 'arm64'}}
|
||||||
|
with:
|
||||||
|
push: true
|
||||||
|
platforms: linux/arm64
|
||||||
|
labels: org.opencontainers.image.source https://github.com/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}
|
||||||
|
tags: ${{ env.IMAGE_REGISTRY }}/${{ env.IMAGE_OWNER }}/${{ env.IMAGE_NAME }}:arm-latest
|
||||||
@@ -1,6 +1,4 @@
|
|||||||
FROM node:14.15.3-alpine AS base
|
FROM nginx:1.19.6-alpine as web
|
||||||
|
|
||||||
FROM nginx:1.19.6-alpine as Web
|
|
||||||
LABEL maintainer="Phoenix (https://github.com/HotaruBlaze)"
|
LABEL maintainer="Phoenix (https://github.com/HotaruBlaze)"
|
||||||
COPY docker/nginx.conf /etc/nginx/nginx.conf
|
COPY docker/nginx.conf /etc/nginx/nginx.conf
|
||||||
COPY docker/web.conf /etc/nginx/conf.d/web.conf
|
COPY docker/web.conf /etc/nginx/conf.d/web.conf
|
||||||
|
|||||||
Reference in New Issue
Block a user