-
Notifications
You must be signed in to change notification settings - Fork 326
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
vault: add support for wan federation with Vault when ACLs are enabled #1025
Conversation
bf10149
to
1c03ab2
Compare
.circleci/config.yml
Outdated
@@ -70,7 +70,7 @@ commands: | |||
type: string | |||
consul-k8s-image: | |||
type: string | |||
default: "docker.mirror.hashicorp.services/hashicorpdev/consul-k8s-control-plane:latest" | |||
default: "ishustava/consul-k8s-dev:02-08-2022-d21554d8" |
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.
todo: remove before merging
@@ -4,7 +4,9 @@ | |||
{{- if and .Values.global.acls.createReplicationToken (not .Values.global.acls.manageSystemACLs) }}{{ fail "if global.acls.createReplicationToken is true, global.acls.manageSystemACLs must be true" }}{{ end -}} | |||
{{- if .Values.global.bootstrapACLs }}{{ fail "global.bootstrapACLs was removed, use global.acls.manageSystemACLs instead" }}{{ end -}} | |||
{{- if .Values.global.acls.manageSystemACLs }} | |||
{{- /* We don't render this job when server.updatePartition > 0 because that | |||
{{- if and .Values.global.secretsBackend.vault.enabled .Values.global.acls.replicationToken.secretName (not .Values.global.secretsBackend.vault.manageSystemACLsRole) }}{{ fail "global.secretsBackend.vault.manageSystemACLsRole must be set if global.secretsBackend.vault.enabled is true and global.acls.replicationToken is provided" }}{{ end -}} | |||
{{- if or (and .Values.global.acls.replicationToken.secretName (not .Values.global.acls.replicationToken.secretKey)) (and .Values.global.acls.replicationToken.secretKey (not .Values.global.acls.replicationToken.secretName))}}{{ fail "both global.acls.replicationToken.secretKey and global.acls.replicationToken.secretName must be set if one of them is provided" }}{{ end -}} |
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.
This simplifies logic and testing across our templates since we don't have to test for the combinations when replication token secret name is provided but not secret key and vice versa.
fe6b041
to
55a28c6
Compare
1c03ab2
to
b342d8c
Compare
55a28c6
to
9ae1d33
Compare
b342d8c
to
64cb04f
Compare
13c9839
to
ec7e05e
Compare
64cb04f
to
d1c08cd
Compare
@@ -75,6 +75,10 @@ spec: | |||
"vault.hashicorp.com/agent-inject-secret-serverca.crt": {{ .Values.global.tls.caCert.secretName }} | |||
"vault.hashicorp.com/agent-inject-template-serverca.crt": {{ include "consul.serverTLSCATemplate" . }} | |||
{{- end }} | |||
{{- if (and .Values.global.acls.replicationToken.secretName (not .Values.global.acls.createReplicationToken)) }} | |||
"vault.hashicorp.com/agent-inject-secret-replication-token-config.hcl": "{{ .Values.global.acls.replicationToken.secretName }}" | |||
"vault.hashicorp.com/agent-inject-template-replication-token-config.hcl": {{ template "consul.vaultReplicationTokenConfigTemplate" . }} |
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.
This is awesome!
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.
🔥
8e0e4e3
to
3f5383c
Compare
@@ -51,7 +51,7 @@ func NewCLICluster( | |||
ctx environment.TestContext, | |||
cfg *config.TestConfig, | |||
releaseName string, | |||
) Cluster { | |||
) *CLICluster { |
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.
🙏🏻 Thank you!
3f5383c
to
43f6307
Compare
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.
Spectacular! I always enjoy how clear your code is, Iryna. Great work.
hashicorp#1025) * Revamp issue template and provide verbiage on +1 for tracking interest
Changes proposed in this PR:
How I've tested this PR:
acceptance tests
How I expect reviewers to test this PR:
👀
Checklist: