-
Notifications
You must be signed in to change notification settings - Fork 385
Annotate deployments with hashed extraconfig #550
Conversation
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.
Looks great! I tested it, and clients and servers were upgraded. I was in awe 😄
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.
Looks great!
Oh, I think we need to add a changelog entry |
86ce70c
to
65a0941
Compare
@@ -1,5 +1,11 @@ | |||
## Unreleased | |||
|
|||
IMPROVEMENTS: |
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.
I think this might need to be listed as a breaking change too? Since doing a full restart of all the clients and servers can be destructive.
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.
Sure thing.
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.
done 👍
- When the extra config for a client or server is updated, it updates the underlying configMap but has no way of informing the server statefulSet or client daemonSet of the update.With this PR, the values for server.extraConfig & client.extraConfig are saved as annotations on the server statefulSet spec and client daemonsetSpec respectfully. If a user updates the extraConfig and performs a `helm upgrade`, it will force a reconcile of the server and client pods (depending on what changed) and will keep them updated with the latest config. Signed-off-by: Ashwin Venkatesh <[email protected]>
65a0941
to
5a184df
Compare
Co-authored-by: Luke Kysow <[email protected]>
When the extra config for a client or server is updated, it updates the underlying configMap but has no way of informing the server statefulSet or client daemonSet of the update.With this PR, the values for server.extraConfig & client.extraConfig are saved as annotations on the server statefulSet spec and client daemonsetSpec respectfully. If a user updates the extraConfig and performs a
helm upgrade
, it will force a reconcile of the server and client pods (depending on what changed) and will keep them updated with the latest config.Signed-off-by: Ashwin Venkatesh [email protected]
Testing:
• Install consul using
helm install
with some values file• Update
sever.extraConfig
and perform ahelm upgrade
with the file• Observe
kubectl get pods
. The existing server pod will terminate and a new one will spin up with the updated config. You can compare the value of the annotation "consul.hashicorp.com/config-checksum" before and after the upgrade to see it change.• Update
client.extraConfig
and perform ahelm upgrade
with the file• Observe
kubectl get pods
. The existing client pod will terminate and a new one will spin up with the updated config. You can compare the value of the annotation "consul.hashicorp.com/config-checksum" before and after the upgrade to see it change.• Be in awe.