Skip to content

Commit

Permalink
Merge branch 'main' into mirror-ago-hyperchain-pro-37-12eac32a1768e55…
Browse files Browse the repository at this point in the history
…23970a78c0d8d4a7d09f15ce0
  • Loading branch information
agolajko authored Oct 3, 2023
2 parents ed0f675 + 8df1127 commit bac70ab
Show file tree
Hide file tree
Showing 10 changed files with 115 additions and 62 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-external-node-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
jobs:
build-images:
name: External Node - Build and Push Docker Image
runs-on: [self-hosted, ci-runner]
runs-on: [matterlabs-ci-runner]
steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-gar-reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ on:
jobs:
build-gar-prover:
name: Build GAR prover
runs-on: [self-hosted, ci-runner]
runs-on: [matterlabs-ci-runner]
strategy:
fail-fast: false
matrix:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-local-node-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
jobs:
build-images:
name: Local Node - Build and Push Docker Image
runs-on: [self-hosted, ci-runner]
runs-on: [matterlabs-ci-runner]
steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-prover-fri-gpu-gar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ on:
jobs:
build-gar-prover-fri-gpu:
name: Build prover FRI GPU GAR
runs-on: [self-hosted, ci-runner]
runs-on: [matterlabs-ci-runner]
steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
with:
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@ name: CI

on:
pull_request:
paths-ignore:
- ".github/workflows/zk-environment.publish.yml"
- "docker/zk-environment/Dockerfile"
- "docker/zk-environment-cuda-12-0/Dockerfile"
- "docker/zk-rust-nightly-environment/Dockerfile"
merge_group:
push:
branches:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:

jobs:
generate:
runs-on: [self-hosted, ci-runner]
runs-on: [matterlabs-ci-runner]

steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vm-perf-comparison.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
jobs:
vm-benchmarks:
name: Run VM benchmarks
runs-on: [self-hosted, ci-runner]
runs-on: [matterlabs-ci-runner]

steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/vm-perf-to-prometheus.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ concurrency: vm-benchmarks
jobs:
vm-benchmarks:
name: Run VM benchmarks
runs-on: [self-hosted, ci-runner]
runs-on: [matterlabs-ci-runner]

steps:
- uses: actions/checkout@v3
Expand Down
50 changes: 0 additions & 50 deletions .github/workflows/zk-environment-cuda-12-0.publish.yml

This file was deleted.

108 changes: 103 additions & 5 deletions .github/workflows/zk-environment.publish.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: publish zk-environment docker image
name: publish zk-environment docker images

on:
pull_request:
Expand All @@ -8,15 +8,47 @@ on:
paths:
- "docker/zk-environment/Dockerfile"
- ".github/workflows/zk-environment.publish.yml"
- "docker/zk-environment-cuda-12-0/Dockerfile"
- ".github/workflows/zk-environment-cuda-12-0.publish.yml"
- "docker/zk-rust-nightly-environment/Dockerfile"
- ".github/workflows/rust-nightly-environment.publish.yml"
workflow_dispatch:
branches:
- "main"

jobs:
push_to_registry:
if: github.event.pull_request.merged == true || github.event_name == 'workflow_dispatch'
name: Push Docker image to Docker Hub
runs-on: [self-hosted, ci-runner]
changed_files:
name: Changed files
outputs:
zk_environment: ${{ steps.changed-files-yaml.outputs.zk_env_any_changed }}
zk_environment_cuda_12: ${{ steps.changed-files-yaml.outputs.zk_env_cuda_12_any_changed }}
rust_nightly: ${{ steps.changed-files-yaml.outputs.rust_nightly_any_changed }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
with:
submodules: "recursive"

- name: Get changed files
id: changed-files-yaml
uses: tj-actions/changed-files@v39
with:
files_yaml: |
zk_env:
- docker/zk-environment/Dockerfile
- .github/workflows/zk-environment.publish.yml
zk_env_cuda_12:
- docker/zk-environment-cuda-12-0/Dockerfile
- .github/workflows/zk-environment-cuda-12-0.publish.yml
rust_nightly:
- docker/zk-rust-nightly-environment/Dockerfile
- .github/workflows/rust-nightly-environment.publish.yml
zk_environment:
if: needs.changed_files.outputs.zk_environment == 'true' && github.event.pull_request.merged == true || github.event_name == 'workflow_dispatch'
name: Push zk-environment docker image to Docker Hub
runs-on: ubuntu-latest
needs: changed_files
steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
with:
Expand Down Expand Up @@ -51,3 +83,69 @@ jobs:
tags: "matterlabs/zk-environment:latest2.0"
file: docker/zk-environment/Dockerfile
no-cache: true

rust_nightly:
if: needs.changed_files.outputs.rust_nightly == 'true' && github.event.pull_request.merged == true || github.event_name == 'workflow_dispatch'
name: Push rust nightly docker image to Docker Hub
needs: changed_files
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
with:
submodules: "recursive"

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@f03ac48505955848960e80bbb68046aa35c7b9e7 # v2

- name: Log in to Docker Hub
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # v2.1.0
with:
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Docker image
uses: docker/build-push-action@3b5e8027fcad23fda98b2e3ac259d8d67585f671 # v4.0.0
with:
context: .
push: true
tags: "matterlabs/zksync_rust:nightly"
file: docker/zk-rust-nightly-environment/Dockerfile
no-cache: true


zk_environment_cuda_12:
if: needs.changed_files.outputs.zk_environment_cuda_12 == 'true' github.event.pull_request.merged == true || github.event_name == 'workflow_dispatch'
name: Push zk-environment cuda 12 docker image to Docker Hub
runs-on: [matterlabs-ci-runner]
needs: changed_files
steps:
- uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3
with:
submodules: "recursive"

- name: Login to us-central1 GAR
run: |
gcloud auth print-access-token --lifetime=7200 --impersonate-service-account=gha-ci-runners@matterlabs-infra.iam.gserviceaccount.com | docker login -u oauth2accesstoken --password-stdin https://us-docker.pkg.dev
- name: Log in to Docker Hub
uses: docker/login-action@f4ef78c080cd8ba55a85445d5b36e214a81df20a # v2.1.0
with:
username: ${{ secrets.DOCKERHUB_USER }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Build and push
uses: docker/build-push-action@v4
with:
context: .
file: docker/zk-environment-cuda-12-0/Dockerfile
push: true
target: nvidia-tools
tags: |
us-docker.pkg.dev/matterlabs-infra/matterlabs-docker/zk-environment-cuda-12-0:latest
matterlabs/zk-environment:cuda-12-0-latest

0 comments on commit bac70ab

Please sign in to comment.