Skip to content

Commit

Permalink
chore(bors): merge pull request #536
Browse files Browse the repository at this point in the history
536: fix(chart): allow scaling etcd via replicaCount and Helm upgrade r=tiagolobocastro a=michaelbeaumont

## Description

The [etcd chart dynamically sets this value based on whether Helm is installing or upgrading](https://github.com/bitnami/charts/blob/etcd/8.6.0/bitnami/etcd/templates/statefulset.yaml#L195). We shouldn't pin it to `"new"`

## Motivation and Context
See openebs/mayastor#1732 and fixes openebs/mayastor#1659

It's supposed to be possible to scale etcd via the replica count with Helm.

## How Has This Been Tested?
Tested via setting both `initialClusterState` to `"existing"` and changing `replicaCount`.

We then see on `etcd-1` something like:

```
etcd 15:04:14.85
etcd 15:04:14.85 Welcome to the Bitnami etcd container
etcd 15:04:14.85 Subscribe to project updates by watching https://github.com/bitnami/containers
etcd 15:04:14.85 Submit issues and feature requests at https://github.com/bitnami/containers/issues
etcd 15:04:14.85
etcd 15:04:14.85 INFO  ==> ** Starting etcd setup **
etcd 15:04:14.86 INFO  ==> Validating settings in ETCD_* env vars..
etcd 15:04:14.86 WARN  ==> You set the environment variable ALLOW_NONE_AUTHENTICATION=yes. For safety reasons, do not use this flag in a production environment.
etcd 15:04:14.87 INFO  ==> Initializing etcd
etcd 15:04:14.87 INFO  ==> Generating etcd config file using env variables
etcd 15:04:14.88 INFO  ==> There is no data from previous deployments
etcd 15:04:14.88 INFO  ==> Adding new member to existing cluster
etcd 15:04:14.98 INFO  ==> Loading env vars of existing cluster
etcd 15:04:14.99 INFO  ==> Obtaining cluster member ID
etcd 15:04:14.99 INFO  ==> Starting etcd in background
etcd 15:04:28.10 INFO  ==> Stored member ID: 2c17af324709f873
etcd 15:04:28.10 INFO  ==> Stopping etcd
```

## Types of changes
<!

Co-authored-by: Mike Beaumont <mjboamail@gmail.com>
mayastor-bors and michaelbeaumont committed Sep 12, 2024

Verified

This commit was signed with the committer’s verified signature.
jcubic Jakub T. Jankiewicz
2 parents e10b158 + 68166e9 commit 6a2bf49
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion chart/values.yaml
Original file line number Diff line number Diff line change
@@ -516,7 +516,6 @@ etcd:
pullSecrets: []
# extra debug information on logs
debug: false
initialClusterState: "new"

# -- Pod anti-affinity preset
# Ref: https://kubernetes.io/docs/concepts/scheduling-eviction/assign-pod-node/#inter-pod-affinity-and-anti-affinity

0 comments on commit 6a2bf49

Please sign in to comment.