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

cloud: add statefulset config for EKS multi-region #51775

Merged
merged 6 commits into from
Aug 21, 2020
Merged

Conversation

taroface
Copy link
Collaborator

@taroface taroface commented Jul 22, 2020

This StatefulSet config is meant for use with the EKS multi-region docs (WIP).

  • Added an initContainer that determines the AZ of each pod.
  • Added namespace field to fill in with a region-appropriate namespace.
  • Modified --join and --locality in the start command for the user to customize with namespace/region names. I am unclear on whether the values here need to match the namespace defined for the cluster above.
  • Added the memory/CPU requests & limits block that is in the single-region configs (but not the current multi-region config).
  • Also added dns-lb-eks.yaml for creating an EKS network load balancer.
  • Also added configmap.yaml for modifying the Corefile.

@taroface taroface requested a review from DuskEagle July 22, 2020 16:31
@cockroach-teamcity
Copy link
Member

This change is Reviewable

--advertise-host $(hostname -f)
--http-addr 0.0.0.0
# TODO: Replace the placeholder values in --join and --locality with the namespace of the CockroachDB cluster in each region (e.g., us-east-1).
# --join cockroachdb-0.cockroachdb.<cluster-namespace-1>,cockroachdb-1.cockroachdb.<cluster-namespace-1>,cockroachdb-2.cockroachdb.<cluster-namespace-1>,cockroachdb-0.cockroachdb.<cluster-namespace-2>,cockroachdb-1.cockroachdb.<cluster-namespace-2>,cockroachdb-2.cockroachdb.<cluster-namespace-2>,cockroachdb-0.cockroachdb.<cluster-namespace-3>,cockroachdb-1.cockroachdb.<cluster-namespace-3>,cockroachdb-2.cockroachdb.<cluster-namespace-3>
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Taking into account this comment on the --join flag, am I safe to remove one node (e.g. cockroachdb-2) from each region here?

Copy link
Member

@DuskEagle DuskEagle left a comment

Choose a reason for hiding this comment

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

Reviewed 1 of 1 files at r2, 1 of 1 files at r3, 1 of 1 files at r4.
Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @taroface)

a discussion (no related file):
The Kubernetes manifests look good to me, as long as there's other documentation to go along with it. It might be helpful to add a README about how to use these manifests. I realize there might be some text on the docs site, but if people find these manifests without going through the docs site, they might be confused on how to use them.

Relatedly, it might be nice to create a separate directory for the multiregion EKS manifests, to separate it from the existing manifests in this directory.



cloud/kubernetes/multiregion/cockroachdb-statefulset-secure-eks.yaml, line 253 at r4 (raw file):

Previously, taroface (Ryan Kuo) wrote…

Taking into account this comment on the --join flag, am I safe to remove one node (e.g. cockroachdb-2) from each region here?

You're definitely safe to, though I also think it's fine to leave it.

@taroface
Copy link
Collaborator Author

@DuskEagle TFTR! I moved the files and added a README, also slightly updating the existing README in multiregion.

Copy link
Member

@DuskEagle DuskEagle left a comment

Choose a reason for hiding this comment

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

Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @DuskEagle and @taroface)


cloud/kubernetes/multiregion/eks/README.md, line 73 at r5 (raw file):

- `region2` and `region3` with the namespaces in which the CockroachDB pods will run in the other 2 regions.

- `ip1`, `ip2`, and `ip3` with the IP addresses of the EKS instances in the region.

This should be the IP addresses of the Network Load Balancerss in the other regions, not the EKS VMs.

@taroface
Copy link
Collaborator Author

bors r+

@craig
Copy link
Contributor

craig bot commented Aug 21, 2020

Build succeeded:

@craig craig bot merged commit 2a1e9ce into master Aug 21, 2020
@jordanlewis jordanlewis deleted the taroface-patch-2 branch December 23, 2020 05:29
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