-
Notifications
You must be signed in to change notification settings - Fork 143
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
K8SPSMDB-1140: Allow users to override hostnames in replset config #1640
Conversation
kubectl_bin apply -f ${test_dir}/conf/external-services.yml | ||
|
||
echo "patching PSMDB cluster with replsetOverrides: ${cluster}" | ||
sed "s/NAMESPACE/${namespace}/g" ${test_dir}/conf/${cluster}-overridden.yml > ${tmp_dir}/${cluster}-overridden.yml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[shfmt] reported by reviewdog 🐶
sed "s/NAMESPACE/${namespace}/g" ${test_dir}/conf/${cluster}-overridden.yml > ${tmp_dir}/${cluster}-overridden.yml | |
sed "s/NAMESPACE/${namespace}/g" ${test_dir}/conf/${cluster}-overridden.yml >${tmp_dir}/${cluster}-overridden.yml |
kubectl_bin apply -f ${test_dir}/conf/external-services.yml | ||
|
||
echo "creating PSMDB cluster: ${cluster}" | ||
sed "s/NAMESPACE/${namespace}/g" ${test_dir}/conf/${cluster}-overridden.yml > ${tmp_dir}/${cluster}-overridden.yml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[shfmt] reported by reviewdog 🐶
sed "s/NAMESPACE/${namespace}/g" ${test_dir}/conf/${cluster}-overridden.yml > ${tmp_dir}/${cluster}-overridden.yml | |
sed "s/NAMESPACE/${namespace}/g" ${test_dir}/conf/${cluster}-overridden.yml >${tmp_dir}/${cluster}-overridden.yml |
@@ -6304,6 +6312,21 @@ spec: | |||
format: int32 | |||
type: integer | |||
type: object | |||
replsetOverrides: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add it as an example into cr.yaml
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
6bbf2a8
to
8bde431
Compare
commit: d4f82a7 |
CHANGE DESCRIPTION
Problem:
There's no way to specify hostnames in replset config. Some of our users want to override hostnames to support their multi-cluster topologies.
Solution:
This PR introduces a new field called
replsetOverrides
to directly influence replset configuration:Once you override hostnames, operator will start changing hosts in replset configuration one by one (secondaries first, primary last).
While doing this, I also wanted to allow users to add custom tags to replset members.
replsetOverrides
field also allow specifying tags:CHECKLIST
Jira
Needs Doc
) and QA (Needs QA
)?Tests
compare/*-oc.yml
)?Config/Logging/Testability