-
Notifications
You must be signed in to change notification settings - Fork 2
64 lines (53 loc) · 1.79 KB
/
publish_docker_image.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: Publish fhevm-tfhe-cli
on:
workflow_dispatch:
inputs:
fhevm_tfhe_cli_tag:
description: 'fhEVM-TFHE-CLI tool docker image tag (default: latest)'
default: 'latest'
type: string
required: true
ref_to_build_fhevm_tfhe_cli:
description: 'Branch, tag or commit SHA1 to checkout fhEVM-TFHE-CLI (build)'
required: true
default: "main"
type: string
env:
DOCKER_IMAGE: ghcr.io/zama-ai/fhevm-tfhe-cli
jobs:
push_to_registry:
name: Push Docker image to GitHub Container Registry
runs-on: ubuntu-latest
steps:
- name: Check out fhevm-tfhe-cli
uses: actions/checkout@v3
with:
repository: zama-ai/fhevm-tfhe-cli
ref: ${{ inputs.ref_to_build_fhevm_tfhe_cli }}
- name: Login to GitHub Container Registry
uses: docker/login-action@49ed152c8eca782a232dede0303416e8f356c37b
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Check OS
run: |
lscpu
uname -r
lsb_release -a
- name: List files in the repository
run: |
ls ${{ github.workspace }}
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@4c0219f9ac95b02789c1075625400b2acbff50b1
with:
platforms: linux/amd64,linux/arm64
- name: Build and push Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
with:
context: .
platforms: linux/amd64,linux/arm64
file: Dockerfile
push: true
tags: ${{ env.DOCKER_IMAGE }}:${{ inputs.fhevm_tfhe_cli_tag }},${{ env.DOCKER_IMAGE }}:latest
labels: fhevm-tfhe-cli