Skip to content

Commit

Permalink
Merge branch 'master' into soloseng/governance-slasher
Browse files Browse the repository at this point in the history
  • Loading branch information
soloseng committed Dec 18, 2023
2 parents ca6ea60 + 53b836c commit c63fb6a
Show file tree
Hide file tree
Showing 200 changed files with 8,493 additions and 4,017 deletions.
5 changes: 0 additions & 5 deletions .changeset/cold-jobs-pay.md

This file was deleted.

10 changes: 0 additions & 10 deletions .changeset/cool-waves-switch.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/few-cycles-doubt.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/light-buses-love.md

This file was deleted.

6 changes: 0 additions & 6 deletions .changeset/tiny-chairs-poke.md

This file was deleted.

6 changes: 3 additions & 3 deletions .github/workflows/celo-monorepo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ jobs:
code-${{ github.sha }}
- name: Detect files changed in PR (or commit), and expose as output
id: changed-files
uses: tj-actions/changed-files@v37
uses: tj-actions/changed-files@v40
with:
# Using comma as separator to be able to easily match full paths (using ,<path>)
separator: ','
Expand Down Expand Up @@ -279,9 +279,9 @@ jobs:
- name: Protocol Governance Voting
command: |
yarn --cwd packages/protocol test governance/voting/
- name: Protocol Stability
- name: Protocol scripts test
command: |
yarn --cwd packages/protocol test stability/
yarn --cwd packages/protocol test:scripts
steps:
- uses: actions/checkout@v4
with:
Expand Down
42 changes: 0 additions & 42 deletions .github/workflows/container-all-monorepo.yml

This file was deleted.

42 changes: 0 additions & 42 deletions .github/workflows/container-celotool.yml

This file was deleted.

42 changes: 0 additions & 42 deletions .github/workflows/container-cli.yml

This file was deleted.

159 changes: 159 additions & 0 deletions .github/workflows/containers.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
---
name: Build containers

on:
push:
paths:
- 'dockerfiles/**'
branches:
- master
pull_request:
paths:
- 'dockerfiles/**'
workflow_dispatch:

jobs:
changed-files:
runs-on: ubuntu-latest
outputs:
# Propagate more outputs if you need https://github.com/tj-actions/changed-files#outputs
# Adding a initial comma so ',<path>' matches also for the first file
all_modified_files: ',${{ steps.changed-files.outputs.all_modified_files }}'
steps:
- uses: actions/checkout@v4
- name: Detect files changed in PR (or commit), and expose as output
id: changed-files
uses: tj-actions/changed-files@v40
with:
# Using comma as separator to be able to easily match full paths (using ,<path>)
separator: ','

# Celotool images
celotool-build-dev:
uses: celo-org/reusable-workflows/.github/workflows/[email protected]
name: Build us-west1-docker.pkg.dev/devopsre/dev-images/celotool:${{ github.sha }}
needs: changed-files
if: |
github.ref != 'refs/heads/master' &&
contains(needs.changed-files.outputs.all_modified_files, ',dockerfiles/celotool/Dockerfile')
with:
workload-id-provider: projects/1094498259535/locations/global/workloadIdentityPools/gh-celo-monorepo/providers/github-by-repos
service-account: '[email protected]'
artifact-registry: us-west1-docker.pkg.dev/devopsre/dev-images/celotool
tags: ${{ github.sha }}
platforms: linux/amd64
context: .
file: dockerfiles/celotool/Dockerfile
trivy: true
celotool-build:
uses: celo-org/reusable-workflows/.github/workflows/[email protected]
name: Build us-west1-docker.pkg.dev/devopsre/celo-monorepo/celotool:${{ github.sha }}
needs: changed-files
if: |
github.ref == 'refs/heads/master' &&
contains(needs.changed-files.outputs.all_modified_files, ',dockerfiles/celotool/Dockerfile')
with:
workload-id-provider: projects/1094498259535/locations/global/workloadIdentityPools/gh-celo-monorepo-master/providers/github-by-repos
service-account: '[email protected]'
artifact-registry: us-west1-docker.pkg.dev/devopsre/celo-monorepo/celotool
tags: ${{ github.sha }}
platforms: linux/amd64
context: .
file: dockerfiles/celotool/Dockerfile
trivy: true

# All monorepo
celomonorepo-build-dev:
uses: celo-org/reusable-workflows/.github/workflows/[email protected]
name: Build us-west1-docker.pkg.dev/devopsre/dev-images/monorepo:${{ github.sha }}
needs: changed-files
if: |
github.ref != 'refs/heads/master' &&
contains(needs.changed-files.outputs.all_modified_files, ',dockerfiles/all-monorepo/Dockerfile')
with:
workload-id-provider: projects/1094498259535/locations/global/workloadIdentityPools/gh-celo-monorepo/providers/github-by-repos
service-account: '[email protected]'
artifact-registry: us-west1-docker.pkg.dev/devopsre/dev-images/monorepo
tags: ${{ github.sha }}
context: .
file: dockerfiles/all-monorepo/Dockerfile
trivy: true
celomonorepo-build:
uses: celo-org/reusable-workflows/.github/workflows/[email protected]
name: Build us-west1-docker.pkg.dev/devopsre/celo-monorepo/monorepo:${{ github.sha }}
needs: changed-files
if: |
github.ref == 'refs/heads/master' &&
contains(needs.changed-files.outputs.all_modified_files, ',dockerfiles/all-monorepo/Dockerfile')
with:
workload-id-provider: projects/1094498259535/locations/global/workloadIdentityPools/gh-celo-monorepo-master/providers/github-by-repos
service-account: '[email protected]'
artifact-registry: us-west1-docker.pkg.dev/devopsre/celo-monorepo/monorepo
tags: ${{ github.sha }}
context: .
file: dockerfiles/all-monorepo/Dockerfile
trivy: true

# CeloCli images
celocli-build-dev:
uses: celo-org/reusable-workflows/.github/workflows/[email protected]
needs: changed-files
name: Build us-west1-docker.pkg.dev/devopsre/dev-images/celocli:testing
if: |
github.ref != 'refs/heads/master' &&
contains(needs.changed-files.outputs.all_modified_files, ',dockerfiles/cli-standalone/Dockerfile')
with:
workload-id-provider: projects/1094498259535/locations/global/workloadIdentityPools/gh-celo-monorepo/providers/github-by-repos
service-account: '[email protected]'
artifact-registry: us-west1-docker.pkg.dev/devopsre/dev-images/celocli
tags: testing
context: .
file: dockerfiles/cli-standalone/Dockerfile
trivy: true
celocli-build:
uses: celo-org/reusable-workflows/.github/workflows/[email protected]
needs: changed-files
name: Build us-west1-docker.pkg.dev/devopsre/celo-monorepo/celocli:latest
if: |
github.ref == 'refs/heads/master' &&
contains(needs.changed-files.outputs.all_modified_files, ',dockerfiles/cli-standalone/Dockerfile')
with:
workload-id-provider: projects/1094498259535/locations/global/workloadIdentityPools/gh-celo-monorepo-master/providers/github-by-repos
service-account: '[email protected]'
artifact-registry: us-west1-docker.pkg.dev/devopsre/celo-monorepo/celocli
tags: latest
context: .
file: dockerfiles/cli-standalone/Dockerfile
trivy: true

# Blockscout Metadata crawler images
metadata-crawler-build-dev:
uses: celo-org/reusable-workflows/.github/workflows/[email protected]
needs: changed-files
name: Build us-west1-docker.pkg.dev/devopsre/dev-images/blockscout-metadata-crawler:testing
if: |
github.ref != 'refs/heads/master' &&
contains(needs.changed-files.outputs.all_modified_files, ',dockerfiles/metadata-crawler')
with:
workload-id-provider: projects/1094498259535/locations/global/workloadIdentityPools/gh-celo-monorepo/providers/github-by-repos
service-account: '[email protected]'
artifact-registry: us-west1-docker.pkg.dev/devopsre/dev-images/blockscout-metadata-crawler
tags: testing
context: .
file: dockerfiles/metadata-crawler/Dockerfile
trivy: true
metadata-crawler-build:
uses: celo-org/reusable-workflows/.github/workflows/[email protected]
needs: changed-files
name: Build us-west1-docker.pkg.dev/devopsre/celo-monorepo/blockscout-metadata-crawler:latest
if: |
github.ref == 'refs/heads/master' &&
contains(needs.changed-files.outputs.all_modified_files, ',dockerfiles/metadata-crawler')
with:
workload-id-provider: projects/1094498259535/locations/global/workloadIdentityPools/gh-celo-monorepo/providers/github-by-repos
service-account: '[email protected]'
artifact-registry: us-west1-docker.pkg.dev/devopsre/celo-monorepo/blockscout-metadata-crawler
tags: latest
context: .
file: dockerfiles/metadata-crawler/Dockerfile
trivy: true
2 changes: 1 addition & 1 deletion .github/workflows/protocol_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
name: Run tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
submodules: recursive
- name: Foundry cache
Expand Down
18 changes: 11 additions & 7 deletions .github/workflows/publish-contracts-abi-release.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,19 @@
name: Publish ABIs and Solidity files to NPM
on:
push:
branches: [main]
branches: [release/core-contracts/*]
tags:
- core-contracts.v*
pull_request:

branches: [release/core-contracts/*, master]
paths:
- 'packages/protocol/**'
release:
types: [released]
workflow_dispatch:
inputs:
npm_version:
description: 'NPM version'
npm_tag:
description: 'NPM TAG e.g. alpha, pre-merge (default: canary) '
required: true
type: string
jobs:
Expand Down Expand Up @@ -49,13 +53,13 @@ jobs:
shell: bash
run: yarn

- name: Check if a release should be published
- name: Determine release type and version (or dry run)
# This is what sets the RELEASE_TYPE and RELEASE_VERSION env variables
run: yarn --silent is_contract_release >> "$GITHUB_ENV"
run: yarn --silent determine-release-version >> "$GITHUB_ENV"
working-directory: packages/protocol
env:
GITHUB_TAG: ${{ github.ref_name }}
INPUT_VERSION: ${{ inputs.npm_version }}
NPM_TAG: ${{ inputs.npm_tag }}
- name: 'Build packages which will not need abis'
shell: bash
run: yarn build --ignore @celo/contractkit --ignore @celo/explorer --ignore @celo/celocli --ignore @celo/governance --ignore @celo/metadata-crawler --ignore @celo/celotool --ignore @celo/env-tests --ignore @celo/transactions-uri --ignore @celo/wallet-rpc --include-dependencies
Expand Down
Loading

0 comments on commit c63fb6a

Please sign in to comment.