Skip to content
This repository has been archived by the owner on Jun 21, 2024. It is now read-only.

Commit

Permalink
ci: refactor docker build workflows for all rust crates
Browse files Browse the repository at this point in the history
  • Loading branch information
xvello committed May 3, 2024
1 parent 0e25442 commit 6a43782
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 236 deletions.
Original file line number Diff line number Diff line change
@@ -1,17 +1,21 @@
name: Build capture docker image
name: Build container images

on:
workflow_dispatch:
push:
branches:
- "main"

permissions:
packages: write

jobs:
build:
name: build and publish capture image
name: Build and publish container image
strategy:
matrix:
image:
- capture
- hook-api
- hook-janitor
- hook-worker
runs-on: depot-ubuntu-22.04-4
permissions:
id-token: write # allow issuing OIDC tokens for this workflow run
Expand Down Expand Up @@ -45,7 +49,7 @@ jobs:
id: meta
uses: docker/metadata-action@v4
with:
images: ghcr.io/posthog/hog-rs/capture
images: ghcr.io/posthog/hog-rs/${{ matrix.image }}
tags: |
type=ref,event=pr
type=ref,event=branch
Expand All @@ -57,8 +61,8 @@ jobs:
id: buildx
uses: docker/setup-buildx-action@v2

- name: Build and push capture
id: docker_build_capture
- name: Build and push image
id: docker_build
uses: depot/build-push-action@v1
with:
context: ./
Expand All @@ -69,7 +73,7 @@ jobs:
platforms: linux/arm64
cache-from: type=gha
cache-to: type=gha,mode=max
build-args: BIN=capture
build-args: BIN=${{ matrix.image }}

- name: Capture image digest
run: echo ${{ steps.docker_build_capture.outputs.digest }}
- name: Container image digest
run: echo ${{ steps.docker_build.outputs.digest }}
75 changes: 0 additions & 75 deletions .github/workflows/docker-hook-api.yml

This file was deleted.

75 changes: 0 additions & 75 deletions .github/workflows/docker-hook-janitor.yml

This file was deleted.

75 changes: 0 additions & 75 deletions .github/workflows/docker-hook-worker.yml

This file was deleted.

0 comments on commit 6a43782

Please sign in to comment.