Commit graph

10 commits

Author SHA1 Message Date
Christopher Swenson
d186b6ff29
Add annotation on config change (#1001)
When updating the Vault config (and corresponding)
configmap, we now generate a checksum of the config
and set it as an annotation on both the configmap
and the Vault StatefulSet pod template.

This allows the deployer to know what pods need to
be restarted to pick up the a changed config.

We still recommend using the standard upgrade
[method for Vault on Kubernetes](https://developer.hashicorp.com/vault/tutorials/kubernetes/kubernetes-raft-deployment-guide#upgrading-vault-on-kubernetes),
i.e., using the `OnDelete` strategy
for the Vault StatefulSet, so updating the config
and doing a `helm upgrade` should not trigger the
pods to restart, and then deleting pods one
at a time, starting with the standby pods.

With `kubectl` and `jq`, you can check check which
pods need to be updated by first getting the value
of the current configmap checksum:

```shell
kubectl get pods -o json | jq -r ".items[] | select(.metadata.annotations.\"config/checksum\" != $(kubectl get configmap vault-config -o json | jq '.metadata.annotations."config/checksum"') ) | .metadata.name"
```

Fixes #748.

---------

Co-authored-by: Tom Proctor <tomhjp@users.noreply.github.com>
2024-03-18 11:03:56 -07:00
Theron Voran
742ddb1c52
adding SPDX copyright headers (#844) 2023-02-13 08:48:20 -08:00
Arie Lev
dcb4b10283
Add container based tests documentation (#492)
* update documentation with running unit tests using container

* promote bats version to 1.3.0

* Update CONTRIBUTING.md

Co-authored-by: Jason O'Donnell <2160810+jasonodonnell@users.noreply.github.com>

* Update CONTRIBUTING.md

Co-authored-by: Jason O'Donnell <2160810+jasonodonnell@users.noreply.github.com>

Co-authored-by: Jason O'Donnell <2160810+jasonodonnell@users.noreply.github.com>
2021-04-14 13:05:38 -04:00
Michele Degges
b544e01391
Use docker mirror (#409) 2020-11-23 16:47:25 -08:00
Octavian Ionescu
7dc56ca86f
Fix python dependency in test image (#336) (#337)
In latest alpine release (3.12) there was an intentional change
to drop python support without specify required version: python2
or python3.

Signed-off-by: Octavian Ionescu <itavyg@gmail.com>
2020-06-26 18:03:14 -07:00
Sarah Thompson
7002cc664b
Get acceptance tests running against GKE in CI - merges to master only. (#291)
* Get acceptance tests running against GKE in CI - merges to master only.

* Adding README.md
2020-05-27 17:21:16 +01:00
Theron Voran
77b973c17f
Helm 3 support (#195)
Update chart and tests to Helm 3

Co-authored-by: Matt Piekunka <mpiekunk@users.noreply.github.com>
Co-authored-by: Mike Brancato <mbrancato@users.noreply.github.com>
2020-02-06 08:44:38 -08:00
Mitchell Hashimoto
83fc9d981c
add unit tests that use helm template 2018-09-03 08:42:25 -07:00
Mitchell Hashimoto
7ff71983f1
test/docker: add jq to the Test dockerfile 2018-08-21 10:51:40 -07:00
Mitchell Hashimoto
c7fa40d247
Initial stuff 2018-08-20 15:26:37 -07:00