Skip to content

[Infra] Adapt pocket helm chart for DevNets#682

Merged
okdas merged 12 commits intomainfrom
issue/674-helm-chart-devnet
Apr 20, 2023
Merged

[Infra] Adapt pocket helm chart for DevNets#682
okdas merged 12 commits intomainfrom
issue/674-helm-chart-devnet

Conversation

@okdas
Copy link
Contributor

@okdas okdas commented Apr 14, 2023

Description

This PR introduces changes to the helm chart and go code necessary to deploy the chart on remote networks, and for the community on their hardware.

Issue

#674

Type of change

Please mark the relevant option(s):

  • New feature, functionality or library
  • Bug fix
  • Code health or cleanup

List of changes

  • Renamed pocket-validator helm chart to pocket - as we've decided to use one artifact to host all protocol actors.
  • Made sure the helm chart works on the remote environment
  • Modified DNS names in accordance with new changes/naming conventions

Testing

  • make develop_test; if any code changes were made
  • Docker Compose LocalNet; if any major functionality was changed or introduced
  • k8s LocalNet; if any infrastructure or configuration changes were made
  • Remote devnet
  • e2e tests via Tilt

Required Checklist

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added, or updated, godoc format comments on touched members (see: 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 diagrams in the corresponding README(s)
  • I have added, or updated, documentation and mermaid.js diagrams in shared/docs/* if I updated shared/*README(s)

@okdas okdas added infra Core infrastructure - not protocol related e2e-devnet-test Runs E2E tests on devnet labels Apr 14, 2023
@okdas okdas self-assigned this Apr 14, 2023
@reviewpad reviewpad bot added the medium label Apr 14, 2023
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

The changelog validation failed with the following output:
Missing changelog in module: build/

Changelog verification failed. See error messages for more detail.

Please update the relevant CHANGELOG.md files and ensure they follow the correct format.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

The changelog validation failed with the following output:
Missing changelog in module: build/

Latest date in charts/CHANGELOG.md is incorrect.
Latest: 2023-04-19, Current: 2023-04-18

Latest date in e2e/docs/CHANGELOG.md is incorrect.
Latest: 2023-04-14, Current: 2023-04-18

Latest date in p2p/CHANGELOG.md is incorrect.
Latest: 2023-04-17, Current: 2023-04-18

Changelog verification failed. See error messages for more detail.

Please update the relevant CHANGELOG.md files and ensure they follow the correct format.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

The changelog validation failed with the following output:
Missing changelog in module: build/

Missing changelog in module: e2e/

Latest date in p2p/CHANGELOG.md is incorrect.
Latest: 2023-04-17, Current: 2023-04-19

Changelog verification failed. See error messages for more detail.

Please update the relevant CHANGELOG.md files and ensure they follow the correct format.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

The changelog validation failed with the following output:
Missing changelog in module: build/

Missing changelog in module: e2e/

Latest date in p2p/CHANGELOG.md is incorrect.
Latest: 2023-04-17, Current: 2023-04-19

Changelog verification failed. See error messages for more detail.

Please update the relevant CHANGELOG.md files and ensure they follow the correct format.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

The changelog validation failed with the following output:
Latest date in p2p/CHANGELOG.md is incorrect.
Latest: 2023-04-17, Current: 2023-04-19

Changelog verification failed. See error messages for more detail.

Please update the relevant CHANGELOG.md files and ensure they follow the correct format.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

The changelog validation failed with the following output:
Missing changelog in module: runtime/

Latest date in p2p/CHANGELOG.md is incorrect.
Latest: 2023-04-17, Current: 2023-04-19

Changelog verification failed. See error messages for more detail.

Please update the relevant CHANGELOG.md files and ensure they follow the correct format.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

The changelog validation failed with the following output:
Latest date in p2p/CHANGELOG.md is incorrect.
Latest: 2023-04-17, Current: 2023-04-19

Changelog verification failed. See error messages for more detail.

Please update the relevant CHANGELOG.md files and ensure they follow the correct format.

@okdas okdas requested review from Olshansk and dylanlott April 19, 2023 23:17
@okdas okdas marked this pull request as ready for review April 19, 2023 23:17
@okdas
Copy link
Contributor Author

okdas commented Apr 19, 2023

Initially, I planned to also work on cluster-manager in scope of that PR because it is currently broken on DevNet (it relies on default namespace, however our DevNets are name-spaced). But we need changes in that PR merged sooner to unblock @dylanlott work.

The parent issue (#674) will cover work related to cluster-manager from the next pr.

Copy link
Contributor

@dylanlott dylanlott left a comment

Choose a reason for hiding this comment

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

This PR passed locally for me after an issue with Postgres persistent volume claims was resolved on my local. Otherwise, LGTM 👍✅

@okdas okdas merged commit 67cc9cb into main Apr 20, 2023
@okdas okdas deleted the issue/674-helm-chart-devnet branch April 20, 2023 21:12
labels: ${{ steps.meta.outputs.labels }}
# NB: Uncomment below if arm64 build is needed; arm64 builds are off by default because build times are significant.
platforms: linux/amd64 #,linux/arm64
platforms: linux/amd64 #,linux/arm64
Copy link
Collaborator

Choose a reason for hiding this comment

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

Should we just remove arm?

// it follows the pattern defined in the v1-validator template (/build/localnet/templates/v1-validator-template.yaml.tpl)
// it follows the pattern defined in the pocket helm chart.
func extractValidatorId(validatorName string) string {
if len(validatorName) >= 3 {
Copy link
Collaborator

Choose a reason for hiding this comment

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

Move 3 into a constant and explain where the magic number came from.

func extractValidatorId(validatorName string) string {
if len(validatorName) >= 3 {
return validatorName[len(validatorName)-3:]
re := regexp.MustCompile(`validator-(\d+)-pocket`)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Good candidate to put in an init

serviceAccountName: debug-client-account
initContainers:
- name: wait-for-validator-001-pocket-validator
- name: wait-for-validator-001-pocket
Copy link
Collaborator

Choose a reason for hiding this comment

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

I'm going to have GetSession implemented soon, which means that we're going to be able to have a "dispatch node".

  1. Do you think this would enable us to have a dispatch node rather than using validator001 for everything?
  2. If so, @okdas, can you create a ticket for it?

"sh",
"-c",
'until wget -q -O - "http://validator-001-pocket-validator:50832/v1/health" --timeout=2 --tries=2 --spider >/dev/null 2>&1; do echo waiting for validator-001-pocket-validator to be online and healthy...; sleep 2; done;',
'until wget -q -O - "http://validator-001-pocket:50832/v1/health" --timeout=2 --tries=2 --spider >/dev/null 2>&1; do echo waiting for validator-001-pocket to be online and healthy...; sleep 2; done;',
Copy link
Collaborator

Choose a reason for hiding this comment

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

Ditto, I think a ticket for s/validator-001/disaptch-node for everything in the infra would be appropriate. Thouhgts?

Copy link
Contributor Author

@okdas okdas Apr 20, 2023

Choose a reason for hiding this comment

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

@Olshansk would dispatch node be just another validator in that case? Just a node that is not staked as validator?

Copy link
Collaborator

Choose a reason for hiding this comment

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

It'd be a full node, not necessarily a validator.

bryanchriswhite added a commit that referenced this pull request Apr 24, 2023
* pokt/main:
  Update devlog6.md
  [CLI] Remove logging for end user focused messages (#698)
  [Testing (DUP)] Add /internal/testutil pkg & refactor mockdns test code (#696)
  [Infra] Adapt pocket helm chart for DevNets (#682)
  Update changelog-verify.yml (#691)
bryanchriswhite added a commit that referenced this pull request Apr 25, 2023
* pokt/main:
  [E2E] adds in-cluster config for E2E tests (#689)
  [Makefile] fixes the localnet_db_cli target (#700)
  Update devlog6.md
  [CLI] Remove logging for end user focused messages (#698)
  [Testing (DUP)] Add /internal/testutil pkg & refactor mockdns test code (#696)
  [Infra] Adapt pocket helm chart for DevNets (#682)
  Update changelog-verify.yml (#691)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

e2e-devnet-test Runs E2E tests on devnet infra Core infrastructure - not protocol related waiting-for-review

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants