Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
198 changes: 0 additions & 198 deletions .github/workflows/build-plugin.yaml

This file was deleted.

14 changes: 5 additions & 9 deletions .github/workflows/docker-scan.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ on:
branches:
- master
tags:
- 'v*'
- "v*"
pull_request:

permissions: {}
Expand All @@ -19,10 +19,9 @@ jobs:
strategy:
fail-fast: false
matrix:
file: [Dockerfile, go.Dockerfile]
runs-on: [ubuntu-x64, ubuntu-arm64]

name: grype scanning (${{ matrix.runs-on }}, ${{ matrix.file }})
name: grype scanning (${{ matrix.runs-on }})
runs-on: ${{ matrix.runs-on }}
permissions:
contents: read # clone the repository
Expand All @@ -41,8 +40,7 @@ jobs:
DOCKER_BUILDKIT: 1
BUILDKIT_STEP_LOG_MAX_SIZE: -1
BUILDKIT_STEP_LOG_MAX_SPEED: -1
FILE: ${{ matrix.file }}
run: docker build . -t image-renderer -f "$FILE"
run: docker build . -t image-renderer

- name: Scan with Grype
id: scan
Expand All @@ -60,10 +58,9 @@ jobs:
strategy:
fail-fast: false
matrix:
file: [Dockerfile, go.Dockerfile]
runs-on: [ubuntu-x64, ubuntu-arm64]

name: trivy scanning (${{ matrix.runs-on }}, ${{ matrix.file }})
name: trivy scanning (${{ matrix.runs-on }})
runs-on: ${{ matrix.runs-on }}
permissions:
contents: read # clone the repository
Expand All @@ -82,8 +79,7 @@ jobs:
DOCKER_BUILDKIT: 1
BUILDKIT_STEP_LOG_MAX_SIZE: -1
BUILDKIT_STEP_LOG_MAX_SPEED: -1
FILE: ${{ matrix.file }}
run: docker build . -t image-renderer -f "$FILE"
run: docker build . -t image-renderer

- name: Scan with Trivy
uses: aquasecurity/trivy-action@b6643a29fecd7f34b3597bc6acb0a98b03d33ff8 # 0.33.1
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/docker-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,9 @@ jobs:
strategy:
fail-fast: false
matrix:
file: [Dockerfile, go.Dockerfile]
runs-on: [ubuntu-x64, ubuntu-arm64]

name: acceptance tests (${{ matrix.runs-on }}, ${{ matrix.file }})
name: acceptance tests (${{ matrix.runs-on }})
runs-on: ${{ matrix.runs-on }}
permissions:
contents: read # clone the repository
Expand All @@ -41,8 +40,7 @@ jobs:
DOCKER_BUILDKIT: 1
BUILDKIT_STEP_LOG_MAX_SIZE: -1
BUILDKIT_STEP_LOG_MAX_SPEED: -1
FILE: ${{ matrix.file }}
run: docker build . -t image-renderer -f "$FILE"
run: docker build . -t image-renderer

- name: Read license
if: ${{ github.event.repository.fork == false }}
Expand Down Expand Up @@ -91,7 +89,7 @@ jobs:
if: ${{ steps.tar.outputs.upload == 'true' && (success() || failure()) }}
uses: actions/upload-artifact@v4
with:
name: changed-files-${{ matrix.file }}-${{ matrix.runs-on }}
name: changed-files-${{ matrix.runs-on }}
path: changed-files.tar.xz

# This is the job that is actually required by rulesets.
Expand Down
30 changes: 6 additions & 24 deletions .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,23 +69,11 @@ jobs:
include:
- runs-on: ubuntu-x64
arch: amd64
dockerfile: Dockerfile
suffix: ''
- runs-on: ubuntu-arm64
arch: arm64
dockerfile: Dockerfile
suffix: ''
- runs-on: ubuntu-x64
arch: amd64
dockerfile: go.Dockerfile
suffix: '-golang'
- runs-on: ubuntu-arm64
arch: arm64
dockerfile: go.Dockerfile
suffix: '-golang'

needs: tag
name: Build ${{ matrix.dockerfile }} image for ${{ matrix.arch }}
name: Build image for ${{ matrix.arch }}
runs-on: ${{ matrix.runs-on }}
permissions:
contents: read # required to read the repository contents
Expand Down Expand Up @@ -113,16 +101,16 @@ jobs:
DOCKER_BUILDKIT: 1
BUILDKIT_STEP_LOG_MAX_SIZE: -1
BUILDKIT_STEP_LOG_MAX_SPEED: -1
TAG: ${{ needs.tag.outputs.tag }}${{ matrix.suffix }}-${{ matrix.arch }}
run: docker build . -t "$TAG" -f ${{ matrix.dockerfile }}
TAG: ${{ needs.tag.outputs.tag }}-${{ matrix.arch }}
run: docker build . -t "$TAG"
- name: docker push
env:
TAG: ${{ needs.tag.outputs.tag }}${{ matrix.suffix }}-${{ matrix.arch }}
TAG: ${{ needs.tag.outputs.tag }}-${{ matrix.arch }}
run: docker push "$TAG"
- name: Get digest
id: digest
env:
TAG: ${{ needs.tag.outputs.tag }}${{ matrix.suffix }}-${{ matrix.arch }}
TAG: ${{ needs.tag.outputs.tag }}-${{ matrix.arch }}
run: |
set -euo pipefail
DIGEST=$(docker inspect --format='{{index .RepoDigests 0}}' "$TAG" | cut -d@ -f2)
Expand Down Expand Up @@ -159,9 +147,7 @@ jobs:
run: |
set -euo pipefail
docker manifest create "$TAG" "$TAG"-amd64 "$TAG"-arm64
docker manifest create "$TAG"-golang "$TAG"-golang-amd64 "$TAG"-golang-arm64
docker manifest push "$TAG"
docker manifest push "$TAG"-golang
- name: Create and push :latest manifest
if: github.event_name == 'push' && github.ref_type == 'tag'
env:
Expand All @@ -183,10 +169,7 @@ jobs:
You can pull it using:

```bash
# For the Node.js server:
docker pull ${{ needs.tag.outputs.tag }}
# For the Go server:
docker pull ${{ needs.tag.outputs.tag }}-golang
```

> [!WARNING]
Expand All @@ -196,8 +179,7 @@ jobs:
# Workflow: https://argo-workflows.grafana.net/workflow-templates/render-service-cd/auto-deploy-dev
cd-auto-deploy-dev:
name: Deploy to dev
# disabled while we test the golang image
if: false && startsWith(github.ref, 'refs/tags/v')
if: startsWith(github.ref, 'refs/tags/v')
needs: [tag, build]
runs-on: ubuntu-latest
permissions:
Expand Down
Loading
Loading