fix(translator): pass BackendTLSPolicy TLS IR with empty CAPEMs inste… #342
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Docker | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| permissions: | |
| contents: read | |
| packages: write | |
| jobs: | |
| build: | |
| name: Build (${{ matrix.arch }}) | |
| runs-on: ${{ matrix.arch == 'arm64' && 'ubuntu-24.04-arm' || 'ubuntu-latest' }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| arch: [amd64, arm64] | |
| steps: | |
| - uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c | |
| - name: Docker metadata | |
| id: meta | |
| uses: docker/metadata-action@80c7e94dd9b9319bd5eb7a0e0fe9291e23a2a2e9 | |
| with: | |
| images: ghcr.io/${{ github.repository_owner }}/nantian-controlplane | |
| tags: | | |
| type=sha,prefix=sha-,format=short,suffix=-${{ matrix.arch }} | |
| type=raw,value=latest-${{ matrix.arch }},enable=${{ github.ref == 'refs/heads/main' }} | |
| - name: Login to GHCR | |
| if: github.ref == 'refs/heads/main' | |
| uses: docker/login-action@650006c6eb7dba73a995cc03b0b2d7f5ca915bee | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Build and push | |
| uses: docker/build-push-action@f9f3042f7e2789586610d6e8b85c8f03e5195baf | |
| with: | |
| context: . | |
| push: ${{ github.ref == 'refs/heads/main' }} | |
| tags: ${{ steps.meta.outputs.tags }} | |
| labels: ${{ steps.meta.outputs.labels }} | |
| cache-from: type=gha,scope=build-${{ matrix.arch }} | |
| cache-to: type=gha,mode=max,ignore-error=true,scope=build-${{ matrix.arch }} | |
| manifest: | |
| name: Create multi-arch manifest | |
| runs-on: ubuntu-latest | |
| needs: build | |
| if: github.ref == 'refs/heads/main' | |
| steps: | |
| - name: Set up Docker Buildx | |
| uses: docker/setup-buildx-action@bb05f3f5519dd87d3ba754cc423b652a5edd6d2c | |
| - name: Login to GHCR | |
| uses: docker/login-action@650006c6eb7dba73a995cc03b0b2d7f5ca915bee | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Create multi-arch manifest (SHA) | |
| run: | | |
| SHORT_SHA=$(echo "${{ github.sha }}" | cut -c1-7) | |
| IMAGE="ghcr.io/${{ github.repository_owner }}/nantian-controlplane" | |
| docker buildx imagetools create \ | |
| --tag "${IMAGE}:sha-${SHORT_SHA}" \ | |
| "${IMAGE}:sha-${SHORT_SHA}-amd64" \ | |
| "${IMAGE}:sha-${SHORT_SHA}-arm64" | |
| - name: Create multi-arch manifest (latest) | |
| run: | | |
| SHORT_SHA=$(echo "${{ github.sha }}" | cut -c1-7) | |
| IMAGE="ghcr.io/${{ github.repository_owner }}/nantian-controlplane" | |
| docker buildx imagetools create \ | |
| --tag "${IMAGE}:latest" \ | |
| "${IMAGE}:sha-${SHORT_SHA}-amd64" \ | |
| "${IMAGE}:sha-${SHORT_SHA}-arm64" |