Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extend ccip helm chart to use ccip-scripts for contract deployment #614

Merged
merged 14 commits into from
Mar 22, 2024

Conversation

scheibinger
Copy link
Contributor

@scheibinger scheibinger commented Mar 15, 2024

Motivation

Enable automated E2E testing via providing a workflow to automate deployment of ccip contracts and jobs within devspace/helm setup.

Solution

Added a batch job that will install scripts and contracts as part of helm install/upgrade command.

To provide more context I posted GH comments alongside the source code

@scheibinger scheibinger changed the title CCIP scripts helm WIP CCIP scripts helm Mar 15, 2024

ccip:
chains:
- NetworkId: 1337
Copy link
Contributor Author

@scheibinger scheibinger Mar 15, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

values here are an example values based on the ccip-scripts example input.json from @AnieeG

Base automatically changed from ccip-1795-merge to ccip-develop March 18, 2024 12:55
@scheibinger scheibinger changed the title WIP CCIP scripts helm Extend ccip helm chart to use ccip-scripts for contract deployment Mar 19, 2024
@@ -120,8 +120,8 @@ geth:
runAsUser: 999
runAsGroup: 999
version: v1.12.0
wsrpc-port: 8546
httprpc-port: 8544
Copy link
Contributor Author

@scheibinger scheibinger Mar 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these weren't used anywhere and they were causing issues in helm templates, as it doesn't like dashes. I renamed to camel case

@scheibinger scheibinger marked this pull request as ready for review March 21, 2024 11:53
annotations:
prometheus.io/scrape: 'true'
spec:
initContainers:
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ideally the nodes themselves should have a readiness probe, and we could rely on that for sequencing the deployment. But this can work as some extra protection.

Comment on lines -18 to -21
# Allow all runner pods to access the database pods.
- podSelector:
matchLabels:
app: runner
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cleaning up deprecated reference to runner pods

Copy link
Collaborator

@chainchad chainchad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! The biggest thing is making sure that changes like value name casing is synced on the /chainlink repo too to avoid pain. Are there any values that we should update in Argo too in order to use this? If so, that would be a separate PR on the GitOps repo.

charts/chainlink-cluster/README.md Show resolved Hide resolved
charts/chainlink-cluster/README.md Outdated Show resolved Hide resolved
charts/chainlink-cluster/devspace.yaml Show resolved Hide resolved
charts/chainlink-cluster/templates/ccip-scripts-job.yaml Outdated Show resolved Hide resolved
# This is what defines this resource as a hook. Without this line, the
# job is considered part of the release.
"helm.sh/hook": post-install,post-upgrade
"helm.sh/hook-weight": "0"
Copy link
Contributor Author

@scheibinger scheibinger Mar 21, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@skudasov the job to deploy contracts and other ccip stuff would run here as helm post-install hook.

Running the job is optional and controlled by $.Values.ccip.deployContractsAndJobs flag.

So if there are other use case they can disable it via that flag.

Co-authored-by: chainchad <96362174+chainchad@users.noreply.github.com>
@scheibinger scheibinger enabled auto-merge (squash) March 22, 2024 09:21
@scheibinger scheibinger added crib Create ephemeral environment. and removed crib Create ephemeral environment. labels Mar 22, 2024
@scheibinger scheibinger merged commit a6bdf8e into ccip-develop Mar 22, 2024
71 of 72 checks passed
@scheibinger scheibinger deleted the ccip-scripts-helm branch March 22, 2024 11:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants