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

Keystone in CRIB #14326

Merged
merged 126 commits into from
Jan 10, 2025
Merged

Conversation

HenryNguyen5
Copy link
Contributor

@HenryNguyen5 HenryNguyen5 commented Sep 4, 2024

This PR enables keystone in CRIB. In summary, it:

Note that a good portion of this code will be replaced with work done at chainlink/deployments. It's better IMO to get this merged in sooner rather than later to begin integration work with chainlink/deployments ASAP to avoid continuing duplicate implementations of the same provisioning logic.

TODO:

  • Set mod refs back to their original versions via make gomodslocalupdate
  • Update chainlink aptos to reflect new repo ref

@HenryNguyen5 HenryNguyen5 changed the title CRIB 322 keystone evm contract deployment tooling KIAB Streams Trigger Provisioner Sep 4, 2024
@HenryNguyen5 HenryNguyen5 force-pushed the CRIB-322-keystone-evm-contract-deployment-tooling branch 3 times, most recently from eaad372 to 7abd46d Compare September 18, 2024 23:59
@HenryNguyen5 HenryNguyen5 force-pushed the CRIB-322-keystone-evm-contract-deployment-tooling branch from 6537149 to f0b0226 Compare September 25, 2024 23:00
@HenryNguyen5 HenryNguyen5 force-pushed the CRIB-322-keystone-evm-contract-deployment-tooling branch 2 times, most recently from 3a10b2a to 7dfbe68 Compare October 17, 2024 06:21
Copy link
Contributor

github-actions bot commented Oct 17, 2024

AER Report: CI Core ran successfully ✅

aer_workflow , commit

AER Report: Operator UI CI ran successfully ✅

aer_workflow , commit

@HenryNguyen5 HenryNguyen5 force-pushed the CRIB-322-keystone-evm-contract-deployment-tooling branch 2 times, most recently from 357886c to 9864099 Compare October 25, 2024 16:28
@HenryNguyen5 HenryNguyen5 force-pushed the CRIB-322-keystone-evm-contract-deployment-tooling branch from 7f49528 to b658c21 Compare October 30, 2024 22:33
@HenryNguyen5 HenryNguyen5 marked this pull request as ready for review October 30, 2024 22:33
@HenryNguyen5 HenryNguyen5 requested review from a team as code owners October 30, 2024 22:33
core/services/relay/evm/mercury/transmitter.go Outdated Show resolved Hide resolved
PanicErr(err)

jsonRPCClient, err := rpc.Dial(ethURL)
insecureSkipVerify := os.Getenv("INSECURE_SKIP_VERIFY") == "true"
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Needed to add this since CRIB can run locally via kind, which uses https but a locally generated cert

src.NewDeployJobSpecsCommand(),
src.NewGenerateCribClusterOverridesCommand(),
src.NewDeleteJobsCommand(),
src.NewProvisionKeystoneCommand(),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

For reviewers: This is the main entrypoint, CRIB scripts call into this command only to provision everything. All other commands below are essentially subcmds of this one

src.NewPreprovisionCribCommand(),
src.NewPostprovisionCribCommand(),
src.NewProvisionCapabilitesRegistryCommand(),
src.NewProvisionStreamsTriggerCommand(),
src.NewDeployAndInitializeCapabilitiesRegistryCommand(),
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@cedric-cordenier Can we remove this? I kept it around because I wasnt sure if the team needs this. NewProvisionCapabilitesRegistryCommand handles provisioning CR for crib

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes we can remove this if NewProvisionCapabilitesRegistryCommand handles it.

core/scripts/keystone/main.go Outdated Show resolved Hide resolved
return "provision-keystone"
}

func (g *provisionKeystone) Run(args []string) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

For reviewers: This is the main entrypoint to keystone in CRIB

core/scripts/keystone/src/02_deploy_keystone_workflows.go Outdated Show resolved Hide resolved
@HenryNguyen5 HenryNguyen5 changed the title KIAB Streams Trigger Provisioner Keystone in CRIB Oct 30, 2024
@cl-sonarqube-production
Copy link

Quality Gate failed Quality Gate failed

Failed conditions
C Reliability Rating on New Code (required ≥ A)

See analysis details on SonarQube

Catch issues before they fail your Quality Gate with our IDE extension SonarLint SonarLint

krehermann
krehermann previously approved these changes Oct 31, 2024
core/scripts/go.mod Outdated Show resolved Hide resolved
@@ -1,6 +1,6 @@
module github.com/smartcontractkit/chainlink/tools/goreleaser-config

go 1.23.0
go 1.22.8
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this intentional?

Copy link
Contributor Author

@HenryNguyen5 HenryNguyen5 Dec 20, 2024

Choose a reason for hiding this comment

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

i want to say yes, but i do not remember the reasoning behind it now :/. I could try setting it back and seeing it it breaks any tooling

}

func ensureArtefactsDir(artefactsDir string) {
_, err := os.Stat(artefactsDir)
if err != nil {
Copy link
Contributor

Choose a reason for hiding this comment

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

Should this be checking for a certain kind of error? https://pkg.go.dev/os#IsNotExist

"github.com/stretchr/testify/assert"
)

func TestMustReadNodesList(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
func TestMustReadNodesList(t *testing.T) {
func Test_mustReadNodesList(t *testing.T) {

Copy link
Contributor

@krehermann krehermann left a comment

Choose a reason for hiding this comment

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

This looks good to me

Main request: A README about how to use the tools so that I can push it forward next year

  • minimal cmds to start, run, stop
  • cfg or permission required to use it
  • known limitations

and anything keystone specific that isn't covered in normal crib implementations

@justinkaseman justinkaseman self-requested a review December 20, 2024 22:37
justinkaseman
justinkaseman previously approved these changes Dec 20, 2024
Copy link
Contributor

@justinkaseman justinkaseman left a comment

Choose a reason for hiding this comment

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

This looks good to me

Main request: A README about how to use the tools so that I can push it forward next year

minimal cmds to start, run, stop
cfg or permission required to use it
known limitations
and anything keystone specific that isn't covered in normal crib implementations

I'll pair with Henry early next week to take notes / record a video on this

PR LGTM at a glance, approving to get out of rebase hell, with further usage next week.

@chainchad
Copy link
Collaborator

Notes from call: in the future, will need to chainlink/deployments integrated to this.

@justinkaseman justinkaseman self-requested a review January 10, 2025 21:55
@krehermann krehermann enabled auto-merge January 10, 2025 21:58
@krehermann krehermann added this pull request to the merge queue Jan 10, 2025
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Jan 10, 2025
@krehermann krehermann added this pull request to the merge queue Jan 10, 2025
Merged via the queue into develop with commit adf13dc Jan 10, 2025
173 of 175 checks passed
@krehermann krehermann deleted the CRIB-322-keystone-evm-contract-deployment-tooling branch January 10, 2025 23:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build-publish Build and Publish image to SDLC
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants