Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Tooling] Retrieve keys for all actors from k8s secrets (#903)
## Description <!-- reviewpad:summarize:start --> ### Summary generated by Reviewpad on 14 Jul 23 23:17 UTC This pull request includes a series of patches that make changes to the file `debug.go` in the `shared/k8s` directory. Patch 1/5: The patch retrieves keys for all actors from k8s secrets. It adds support for retrieving private keys for validators, servicers, fisherman, and applications. Patch 2/5: This patch fixes a linter error in the `fetchPrivateKeys` function by updating the function signature to use a single string parameter for `resourceName` and `actor`. Patch 3/5: This patch further fixes linter errors in the same function and shortens the code by removing unnecessary switch cases. Patch 4/5: This patch updates the constant for the secret resource name from `privateKeysSecretResourceNameFisherman` to `privateKeysSecretResourceNameFishermen`. Patch 5/5: This patch fixes a typo in the function name `FetchFishermanPrivateKeys` by updating the privateKeysSecretResourceName to `privateKeysSecretResourceNameFishermen`. Please review these changes and ensure they are appropriate. <!-- reviewpad:summarize:end --> ## Issue Added as a TODO in #869: <img width="1548" alt="Screenshot 2023-07-12 at 5 10 03 PM" src="https://github.com/pokt-network/pocket/assets/1892194/b1409bdd-4240-4993-b7dd-6197beae5500"> ## Type of change Please mark the relevant option(s): - [ ] New feature, functionality or library - [ ] Bug fix - [x] Code health or cleanup - [ ] Major breaking change - [ ] Documentation - [ ] Other <!-- add details here if it a different type of change --> ## List of changes - Fetch keys for all actors from k8s instead of just validators so they can be used in our debug libraries ## Testing - [x] `make develop_test`; if any code changes were made - [x] `make test_e2e` on [k8s LocalNet](https://github.com/pokt-network/pocket/blob/main/build/localnet/README.md); if any code changes were made - [ ] `e2e-devnet-test` passes tests on [DevNet](https://pocketnetwork.notion.site/How-to-DevNet-ff1598f27efe44c09f34e2aa0051f0dd); if any code was changed - [ ] [Docker Compose LocalNet](https://github.com/pokt-network/pocket/blob/main/docs/development/README.md); if any major functionality was changed or introduced - [ ] [k8s LocalNet](https://github.com/pokt-network/pocket/blob/main/build/localnet/README.md); if any infrastructure or configuration changes were made ## Required Checklist - [x] I have performed a self-review of my own code - [x] I have commented my code, particularly in hard-to-understand areas - [ ] I have added, or updated, [`godoc` format comments](https://go.dev/blog/godoc) on touched members (see: [tip.golang.org/doc/comment](https://tip.golang.org/doc/comment)) - [ ] I have tested my changes using the available tooling - [ ] I have updated the corresponding CHANGELOG ### If Applicable Checklist - [ ] I have updated the corresponding README(s); local and/or global - [ ] I have added tests that prove my fix is effective or that my feature works - [ ] I have added, or updated, [mermaid.js](https://mermaid-js.github.io) diagrams in the corresponding README(s) - [ ] I have added, or updated, documentation and [mermaid.js](https://mermaid-js.github.io) diagrams in `shared/docs/*` if I updated `shared/*`README(s) Co-authored-by: Dima Kniazev <[email protected]>
- Loading branch information