chore: add local build action
This commit is contained in:
parent
06f84b5adf
commit
c65aab8b06
2 changed files with 62 additions and 0 deletions
31
.github/workflows/local-build-dev.yaml
vendored
Normal file
31
.github/workflows/local-build-dev.yaml
vendored
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
name: local-build-dev
|
||||
|
||||
# Intended for local network use.
|
||||
# Remote access is possible if the host has a public IP address.
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
env:
|
||||
REGISTRY: ${{ vars.DOCKER_REGISTRY || 'localhost:5000' }}
|
||||
|
||||
jobs:
|
||||
local-build-dev:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Setup Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
with:
|
||||
config-inline: |
|
||||
[registry."${{ env.REGISTRY }}"]
|
||||
http = true
|
||||
insecure = true
|
||||
- name: Build and Push Docker Image
|
||||
uses: docker/build-push-action@v3
|
||||
with:
|
||||
context: .
|
||||
platforms: linux/amd64
|
||||
push: true
|
||||
tags: ${{ env.REGISTRY }}/jws/jws-frontend:dev
|
||||
allow: security.insecure
|
||||
31
.github/workflows/local-build-release.yaml
vendored
Normal file
31
.github/workflows/local-build-release.yaml
vendored
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
name: local-build-release
|
||||
|
||||
# Intended for local network use.
|
||||
# Remote access is possible if the host has a public IP address.
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
env:
|
||||
REGISTRY: ${{ vars.DOCKER_REGISTRY || 'localhost:5000' }}
|
||||
|
||||
jobs:
|
||||
local-build-release:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: Setup Docker Buildx
|
||||
uses: docker/setup-buildx-action@v2
|
||||
with:
|
||||
config-inline: |
|
||||
[registry."${{ env.REGISTRY }}"]
|
||||
http = true
|
||||
insecure = true
|
||||
- name: Build and Push Docker Image
|
||||
uses: docker/build-push-action@v3
|
||||
with:
|
||||
context: .
|
||||
platforms: linux/amd64
|
||||
push: true
|
||||
tags: ${{ env.REGISTRY }}/jws/jws-frontend:latest
|
||||
allow: security.insecure
|
||||
Loading…
Add table
Add a link
Reference in a new issue