68 lines
2.3 KiB
YAML
68 lines
2.3 KiB
YAML
name: Publish L4 nginx-lua to Dockerhub
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
inputs:
|
|
tags:
|
|
description: 'Release Tags'
|
|
|
|
jobs:
|
|
publish_dockerhub_amd64:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Check out the repo
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Log in to Docker Hub
|
|
uses: docker/login-action@v2
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_PASS }}
|
|
|
|
- name: Build nginx-lua and push Docker image
|
|
uses: docker/build-push-action@v3
|
|
with:
|
|
push: true
|
|
tags: bytetrade/openresty:${{ github.event.inputs.tags }}-amd64
|
|
file: framework/l4-bfl-proxy/Dockerfile.nginx
|
|
platforms: linux/amd64
|
|
context: framework/l4-bfl-proxy
|
|
|
|
publish_dockerhub_arm64:
|
|
runs-on: self-hosted
|
|
steps:
|
|
- name: Check out the repo
|
|
uses: actions/checkout@v3
|
|
|
|
- name: Log in to Docker Hub
|
|
uses: docker/login-action@v2
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_PASS }}
|
|
|
|
- name: Build nginx-lua and push Docker image
|
|
uses: docker/build-push-action@v3
|
|
with:
|
|
push: true
|
|
tags: bytetrade/openresty:${{ github.event.inputs.tags }}-arm64
|
|
file: framework/l4-bfl-proxy/Dockerfile.nginx
|
|
platforms: linux/arm64
|
|
context: framework/l4-bfl-proxy
|
|
|
|
publish_manifest:
|
|
needs:
|
|
- publish_dockerhub_amd64
|
|
- publish_dockerhub_arm64
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Log in to Docker Hub
|
|
uses: docker/login-action@v2
|
|
with:
|
|
username: ${{ secrets.DOCKERHUB_USERNAME }}
|
|
password: ${{ secrets.DOCKERHUB_PASS }}
|
|
|
|
- name: Push manifest
|
|
run: |
|
|
docker manifest create bytetrade/openresty:${{ github.event.inputs.tags }} --amend bytetrade/openresty:${{ github.event.inputs.tags }}-amd64 --amend bytetrade/openresty:${{ github.event.inputs.tags }}-arm64
|
|
docker manifest push bytetrade/openresty:${{ github.event.inputs.tags }}
|