Commit 3e68cf01 authored by Matthew Slipper's avatar Matthew Slipper Committed by GitHub

Update contracts publish job to use env vars rather than contexts (#11687)

Contexts are scoped to a specific GitHub user group, which doesn't work with the GitHub merge queue or OSS contributors. This PR updates the packaging job to use raw project-level env vars instead (which are not user-scoped), and to only run on commits to `develop`.
parent 814c9de7
...@@ -35,6 +35,9 @@ parameters: ...@@ -35,6 +35,9 @@ parameters:
docker_publish_dispatch: docker_publish_dispatch:
type: boolean type: boolean
default: false default: false
publish_contract_artifacts_dispatch:
type: boolean
default: false
orbs: orbs:
go: circleci/go@1.8.0 go: circleci/go@1.8.0
...@@ -1474,10 +1477,20 @@ jobs: ...@@ -1474,10 +1477,20 @@ jobs:
- gcp-oidc-authenticate: - gcp-oidc-authenticate:
gcp_cred_config_file_path: /root/gcp_cred_config.json gcp_cred_config_file_path: /root/gcp_cred_config.json
oidc_token_file_path: /root/oidc_token.json oidc_token_file_path: /root/oidc_token.json
service_account_email: GCP_SERVICE_CONTRACTS_ACCOUNT_EMAIL project_id: GCP_TOOLS_ARTIFACTS_PROJECT_ID
service_account_email: GCP_CONTRACTS_PUBLISHER_SERVICE_ACCOUNT_EMAIL
- checkout - checkout
- attach_workspace: { at: "." }
- install-contracts-dependencies - install-contracts-dependencies
- run:
name: Pull artifacts
command: bash scripts/ops/pull-artifacts.sh
working_directory: packages/contracts-bedrock
- run:
name: Build contracts
environment:
FOUNDRY_PROFILE: ci
command: just build
working_directory: packages/contracts-bedrock
- run: - run:
name: Publish artifacts name: Publish artifacts
command: bash scripts/ops/publish-artifacts.sh command: bash scripts/ops/publish-artifacts.sh
...@@ -1497,11 +1510,6 @@ workflows: ...@@ -1497,11 +1510,6 @@ workflows:
jobs: jobs:
- pnpm-monorepo: - pnpm-monorepo:
name: pnpm-monorepo name: pnpm-monorepo
- publish-contract-artifacts:
requires:
- pnpm-monorepo
context:
- oplabs-gcr-release
- contracts-bedrock-tests - contracts-bedrock-tests
- contracts-bedrock-coverage - contracts-bedrock-coverage
- contracts-bedrock-checks: - contracts-bedrock-checks:
...@@ -1955,6 +1963,14 @@ workflows: ...@@ -1955,6 +1963,14 @@ workflows:
- slack - slack
- oplabs-fpp-nodes - oplabs-fpp-nodes
develop-publish-contract-artifacts:
when:
or:
- equal: [ "develop", <<pipeline.git.branch>> ]
- equal: [ true, <<pipeline.parameters.publish_contract_artifacts_dispatch>> ]
jobs:
- publish-contract-artifacts
develop-fault-proofs: develop-fault-proofs:
when: when:
and: and:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment