Skip to content

Commit

Permalink
feat(DATAGO-30305): Upgrade vault server to 1.10.x (#16)
Browse files Browse the repository at this point in the history
* add staticSecretRenderInterval to injector (hashicorp#621)

* make staticSecretRenderInterval default to empty string

* update values schema to add staticSecretRenderInterval

* add test for default value

* adding changelog entry

Co-authored-by: Theron Voran <[email protected]>

* Update jira action (hashicorp#644)

* No longer check for Vault team membership
* Tweak jira states and search parameters

* remove support for the leader-elector container (hashicorp#649)

* vault-helm 0.18.0 release (hashicorp#650)

* Run CI tests in github workflows  (hashicorp#657)

Ports the bats unit, chart-verifier, and bats acceptance tests to use
github workflows and actions. The acceptance tests run using kind, and
run for multiple k8s versions, on pushes to the main branch.

Adds a SKIP_CSI env check in the CSI acceptance test, set in the
workflow if K8s version is less than 1.16.

Adds kubeAdmConfigPatches to the kind config to allow testing the CSI
provider on K8s versions prior to 1.21.

Updates the Secrets Store CSI driver to 1.0.0 in tests.

Makes the HA Vault tests more robust by waiting for all consul client
pods to be Ready, and waits with a timeout for Vault to start
responding as sealed (since the tests on GitHub runners were often
failing at that point).

Co-authored-by: Tom Proctor <[email protected]>

* Configurable PodDisruptionBudget for Injector (hashicorp#653)

* Fix spelling error in server disruptionbudget test (hashicorp#654)

* Make terminationGracePeriodSeconds configurable (hashicorp#659)

Make terminationGracePeriodSeconds configurable for server pod

* injector: ability to set deployment update strategy (continued) (hashicorp#661)

Co-authored-by: Jason Hancock <[email protected]>

* csi: ability to set priorityClassName for csi daemonset pods (hashicorp#670)

* Fixed a small typo (hashicorp#672)

* Disable unit and acceptance tests in CircleCI (hashicorp#675)

* update CONTRIBUTING.md (hashicorp#677)

Link to the discuss forum instead of the old google group and irc
channel. Add info about the CLA.

* add namespace support for openshift route (hashicorp#679)

* Add volumes and env vars to helm hook test pod (hashicorp#673)

* Fix test typo

* Add basic server-test Pod tests

 - This covers all existing functionality that matches what's
   present in server-statefulset.bats

* Fix server-test helm hook Pod rendering

 - Properly adhere to the global.enabled flag and the presence of
   the injector.externalVaultAddr setting, the same way that
   the servers StatefulSet behaves

* Add volumes and env vars to helm hook test pod

 - Uses the same extraEnvironmentVars, volumes and volumeMounts set on
   the server statefulset to configure the Vault server test pod used by
   the helm test hook
 - This is necessary in situations where TLS is configured, but the
   certificates are not affiliated with the k8s CA / part of k8s PKI

 - Fixes hashicorpGH-665

* allow injection of TLS config for OpenShift routes (hashicorp#686)

* Add some tests on top of hashicorp#396

* convert server-route.yaml to unix newlines

* changelog

Co-authored-by: André Becker <[email protected]>
Co-authored-by: Theron Voran <[email protected]>

* Release 0.19.0 (hashicorp#687)

* Add extraLabels for CSI DaemonSet (hashicorp#690)

* Updated hashicorp/vault-csi-provider image to v1.0.0 (hashicorp#689)

* Fix unit test assertions (hashicorp#693)

* vault: bump image to 1.9.3 (hashicorp#695)

Signed-off-by: Lionel H <[email protected]>

* changelog++ (hashicorp#699)

* change helm trigger branch from master to main (hashicorp#700)

* Add namespace to injector-leader-elector role, rolebinding and secret (hashicorp#683)

* allow to configure publishNotReadyAddresses on server services (hashicorp#694)

* Maintain pre-existing Mutating Webhook default values for Kubernetes 1.22 (hashicorp#692)

* Prepare default values for MutatingWebhookConfiguration hashicorp#691
* Add values.yaml values to injector-mutating-webhook.yaml hashicorp#691
* Duplicate and deprecate top-level webhook settings and put them in a webhook object
* Made the new values default with the fallback to the old values.yaml
* Fix _helpers.tpl to support both old and new webhook annotations
* Add new tests and deprecate old ones for injector webhook configuration
* Old tests now work with old values.yaml
* Add all new fields showing that they have priority over old ones
* Add deprecation note to injector.failurePolicy hashicorp#691

* VAULT-571 Matching documented behavior and consul (hashicorp#703)

VAULT-571 Matching documented behavior and consul

Consul's helm template defaults most of the enabled to the special value
`"-"`, which means to inherit from global. This is what is implied
should happen in Vault as well according to the documentation for the
helm chart:

> [global.enabled] The master enabled/disabled configuration. If this is
> true, most components will be installed by default. If this is false,
> no components will be installed by default and manually opting-in is
> required, such as by setting server.enabled to true.

(https://www.vaultproject.io/docs/platform/k8s/helm/configuration#enabled)

We also simplified the chart logic using a few template helpers.

Co-authored-by: Theron Voran <[email protected]>

* Update k8s versions (hashicorp#706)

* tests: updating the four most recent k8s versions

* bump oldest version to 1.16

* docs, Chart.yaml, and changelog for 1.14 -> 1.16

* Fix values schema to support config in YAML (hashicorp#684)

* Support policy/v1 disruptionbudget beyond kube 1.21 (hashicorp#710)

Issue hashicorp#667, adding updates to the disruptionbudget to support new
non beta spec beyond kube 1.21

* Remove unncessary template calls (hashicorp#712)

- As part of VAULT-571 / hashicorp#703 in 7109159, a new vault.serverEnabled
   template was added (and included in vault.mode)

   Various templates were updated accordingly, but those that were
   already calling vault.mode had an additonal call to
   vault.serverEnabled made which was unnecessary

   Remove those

* Issue 629: updated to allow customization of the CLUSTER_ADDR the same… (hashicorp#709)

* Issue hashicorp#629 Updates to allow customization of the CLUSTER_ADDR and unit tests to go with it

* Issue-hashicorp#629 removing extra whitespace I added accidently.

* Issue-hashicorp#629 fixing extra whitespace added.

* Update values.yaml

Co-authored-by: Joaco Muleiro Beltran <[email protected]>

* Issue hashicorp#629 adding changelog

Co-authored-by: Joaco Muleiro Beltran <[email protected]>

* VAULT-5838 Update CSI provider to 1.1.0 (hashicorp#721)

* VAULT-5838 Update CSI provider to 1.1.0

* Update test/acceptance/csi.bats

Co-authored-by: Theron Voran <[email protected]>

Co-authored-by: Theron Voran <[email protected]>

* VUALT-5838 Restore Secrets Store CSI driver to 1.0.0 (hashicorp#722)

1.0.1+ seems to only support Kubernetes 1.19+, so we break support for
1.16 if we upgrade

* Implement support for Topology Spread Constraints (hashicorp#652)

* Implemented support for topology spread constraints

* Update values.yaml

Co-authored-by: Ben Ash <[email protected]>

* Update values.yaml

Co-authored-by: Ben Ash <[email protected]>

* Add topologySpreadConstraints to values schema

* Implement injector deployment topology spread UTs

* also remove string from the relevant schema types

* Implement injector statefulset topology spread UTs

* Implement injector HA statefulset topology UTs

* Allow topologySpreadConstraints to be a string

Co-authored-by: Ellis Tarn <[email protected]>
Co-authored-by: Ben Ash <[email protected]>
Co-authored-by: Christopher Swenson <[email protected]>

* Update the changelog with changes from 614 and 652 (hashicorp#723)

* Update the changelog with changes from 614 and 652

* Update CHANGELOG.md

Co-authored-by: Theron Voran <[email protected]>

Co-authored-by: Theron Voran <[email protected]>

* Prepare v0.20.0 release (hashicorp#727)

---------

Signed-off-by: Lionel H <[email protected]>
Co-authored-by: Kaito Ii <[email protected]>
Co-authored-by: Theron Voran <[email protected]>
Co-authored-by: Tom Proctor <[email protected]>
Co-authored-by: Eric Miller <[email protected]>
Co-authored-by: Takumi Sue <[email protected]>
Co-authored-by: Jason Hancock <[email protected]>
Co-authored-by: Vadim Grek <[email protected]>
Co-authored-by: nikstur <[email protected]>
Co-authored-by: Jacob Mammoliti <[email protected]>
Co-authored-by: Ethan J. Brown <[email protected]>
Co-authored-by: Michele Baldessari <[email protected]>
Co-authored-by: André Becker <[email protected]>
Co-authored-by: Michael Schuett <[email protected]>
Co-authored-by: Troy Fluegge <[email protected]>
Co-authored-by: lion24 <[email protected]>
Co-authored-by: Alvin Huang <[email protected]>
Co-authored-by: Christian <[email protected]>
Co-authored-by: Viacheslav Vasilyev <[email protected]>
Co-authored-by: Remco Buddelmeijer <[email protected]>
Co-authored-by: Christopher Swenson <[email protected]>
Co-authored-by: gw0 <[email protected]>
Co-authored-by: Stephen Herd <[email protected]>
Co-authored-by: Joaco Muleiro Beltran <[email protected]>
Co-authored-by: Ellis Tarn <[email protected]>
Co-authored-by: Ben Ash <[email protected]>
  • Loading branch information
1 parent 270a4b2 commit c2589ad
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ template logic.
{{- $_ := set . "mode" "external" -}}
{{- else if not .serverEnabled -}}
{{- $_ := set . "mode" "external" -}}
{{- else if ne (.Values.server.enabled | toString) "true" -}}
{{- else if not .serverEnabled -}}
{{- $_ := set . "mode" "external" -}}
{{- else if eq (.Values.server.dev.enabled | toString) "true" -}}
{{- $_ := set . "mode" "dev" -}}
Expand Down
2 changes: 1 addition & 1 deletion templates/server-clusterrolebinding.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@ subjects:
- kind: ServiceAccount
name: {{ template "vault.serviceAccount.name" . }}
namespace: {{ .Release.Namespace }}
{{ end }}
{{ end }}
3 changes: 2 additions & 1 deletion test/acceptance/csi.bats
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ check_skip_csi() {

# Install Secrets Store CSI driver
CSI_DRIVER_VERSION=1.0.0
helm install secrets-store-csi-driver https://kubernetes-sigs.github.io/secrets-store-csi-driver/charts/secrets-store-csi-driver-${CSI_DRIVER_VERSION}.tgz?raw=true \
helm install secrets-store-csi-driver secrets-store-csi-driver --repo https://kubernetes-sigs.github.io/secrets-store-csi-driver/charts \
--version="${CSI_DRIVER_VERSION}"
--wait --timeout=5m \
--namespace=acceptance \
--set linux.image.pullPolicy="IfNotPresent" \
Expand Down
3 changes: 3 additions & 0 deletions values.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -874,6 +874,9 @@
"enabled": {
"type": "boolean"
},
"publishNotReadyAddresses": {
"type": "boolean"
},
"externalTrafficPolicy": {
"type": "string"
},
Expand Down
2 changes: 0 additions & 2 deletions values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,6 @@ injector:
# for more details.
#
timeoutSeconds: 30

# namespaceSelector is the selector for restricting the webhook to only
# specific namespaces.
# See https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#matching-requests-namespaceselector
Expand Down Expand Up @@ -1013,7 +1012,6 @@ csi:
extraLabels: {}



# Priority class for csi pods
priorityClassName: ""

Expand Down

0 comments on commit c2589ad

Please sign in to comment.