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

Refactor key management in infra and key funder #3023

Merged
merged 14 commits into from
Dec 6, 2023
Merged

Conversation

tkporter
Copy link
Collaborator

@tkporter tkporter commented Dec 5, 2023

Description

  • Remove the bank role, which we haven't used since the inception of abacus / hyperlane
  • Big changes to key-utils.ts so that there's a single source of truth on what kind of keys are used depending on the role & chain. Before this was sprinkled in a few different places
  • You can now get an object of { [chain]: { [role]: keys[] } }, so it's super clear what kind of key relates to which chain. For example, before we would use the AWS-based relayer key for EVM chains, and then a GCP-based relayer key for non-EVM chains. But this wasn't really honored by key funder - it had no way of knowing to only fund the AWS relayer on EVM chains, and only fund the GCP relayer on non-EVM chains. Same situation for Kathy, where we want to use AWS keys for EVM chains but the GCP key for non-EVM chains
  • On v2 and prior to that we were using the AWS-based key for Kathy. Originally, we also launched v3 this way. However it was changed on v3 to use the GCP key for Kathy, causing us to fund both types of addresses on v3. This makes it more clear that we should be using the AWS-based key for Kathy on EVM chains

Drive-by changes

Related issues

Backward compatibility

Testing

Copy link

changeset-bot bot commented Dec 5, 2023

⚠️ No Changeset found

Latest commit: db5f1f7

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@tkporter tkporter enabled auto-merge (squash) December 6, 2023 15:52
@tkporter tkporter enabled auto-merge (squash) December 6, 2023 15:56
@tkporter tkporter merged commit 1a64cef into main Dec 6, 2023
11 of 18 checks passed
@tkporter tkporter deleted the trevor/refactor-keys branch December 6, 2023 16:35
tkporter added a commit that referenced this pull request Dec 7, 2023
* Remove the `bank` role, which we haven't used since the inception of
abacus / hyperlane
* Big changes to `key-utils.ts` so that there's a single source of truth
on what kind of keys are used depending on the role & chain. Before this
was sprinkled in a few different places
* You can now get an object of `{ [chain]: { [role]: keys[] } }`, so
it's super clear what kind of key relates to which chain. For example,
before we would use the AWS-based relayer key for EVM chains, and then a
GCP-based relayer key for non-EVM chains. But this wasn't really honored
by key funder - it had no way of knowing to only fund the AWS relayer on
EVM chains, and only fund the GCP relayer on non-EVM chains. Same
situation for Kathy, where we want to use AWS keys for EVM chains but
the GCP key for non-EVM chains
* On v2 and prior to that we were using the AWS-based key for Kathy.
Originally, we also launched v3 this way. However it was changed on v3
to use the GCP key for Kathy, causing us to fund both types of addresses
on v3. This makes it more clear that we should be using the AWS-based
key for Kathy on EVM chains

<!--
Are there any minor or drive-by changes also included?
-->

<!--
- Fixes #[issue number here]
-->

<!--
Are these changes backward compatible? Are there any infrastructure
implications, e.g. changes that would prohibit deploying older commits
using this infra tooling?

Yes/No
-->

<!--
What kind of testing have these changes undergone?

None/Manual/Unit Tests
-->
tkporter added a commit that referenced this pull request Dec 7, 2023
### Description

- cherry-picks #3023, which is necessary to stop funding the GCP relayer
key
- makes some additional small changes required to work well with key
funder, specifically to filter out non-EVM chains and non-blessed chains
(like Nautilus). The latter is because the environment specific
multiprovider doesn't include non-blessed chains like Nautilus, and
adding it messes up a bunch of our other core tooling
- small change to #3023 to read in helloworld contract addresses from
the correct environment that i will bring to `main` too

### Drive-by changes

- fix deploy chains for key funder

### Related issues

Part of #3024 

### Backward compatibility

ye

### Testing

ran funding script locally

---------

Co-authored-by: OttBunn <132830906+ottbunn@users.noreply.github.com>
tkporter added a commit that referenced this pull request Dec 7, 2023
…3035)

### Description

- Noticed an issue with #3023 where mainnet3 helloworld addresses were
always used. This uses the correct environment and context
- Also noticed errors with key funder infra because the neutron rpc url
wasn't present - fixed the previous hack to accommodate this
- Filter out non evm or blessed chains from key funder as well

### Drive-by changes

n/a

### Related issues

related to #3024 

### Backward compatibility

yes

### Testing

ran locally
daniel-savu pushed a commit that referenced this pull request Jun 5, 2024
### Description

- cherry-picks #3023, which is necessary to stop funding the GCP relayer
key
- makes some additional small changes required to work well with key
funder, specifically to filter out non-EVM chains and non-blessed chains
(like Nautilus). The latter is because the environment specific
multiprovider doesn't include non-blessed chains like Nautilus, and
adding it messes up a bunch of our other core tooling
- small change to #3023 to read in helloworld contract addresses from
the correct environment that i will bring to `main` too

### Drive-by changes

- fix deploy chains for key funder

### Related issues

Part of #3024 

### Backward compatibility

ye

### Testing

ran funding script locally

---------

Co-authored-by: OttBunn <132830906+ottbunn@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

2 participants