forked from build-trust/ockam
-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (39 loc) · 1.15 KB
/
ockam-artifact.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
name: Ockam Command Docker Artifact Build
on:
push:
branches:
- develop
paths:
- 'implementations/rust/ockam'
- 'tools/docker/ockam'
permissions:
contents: read
env:
ARTIFACT_NAME: ockam-artifact
ORGANIZATION: ${{ github.repository_owner }}
jobs:
build_artifact:
runs-on: ubuntu-22.04
permissions:
packages: write
defaults:
run:
working-directory: ./tools/docker/ockam
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
- uses: docker/login-action@343f7c4344506bcbf9b4de18042ae17996df046d
with:
registry: ghcr.io
username: $ORGANIZATION
password: ${{ secrets.GITHUB_TOKEN }}
- id: buildx
uses: docker/setup-buildx-action@c47758b77c9736f4b2ef4073d4d51994fabfe349
with:
driver-opts: |
image=moby/buildkit:v0.10.6
- name: Build and Push Docker image to container registry
run: |
docker buildx build --push \
--tag ghcr.io/${ORGANIZATION}/${ARTIFACT_NAME}:${{ github.event.pull_request.head.sha }}-$(date +'%b-%d-%Y') \
--file Dockerfile \
--platform linux/amd64 .