Skip to content

Commit

Permalink
chore: delete preStop command
Browse files Browse the repository at this point in the history
There is a risk that preStop will fail. When persistence is enabled, preStop failure can lead to inconsistent emqx cluster data
  • Loading branch information
Rory-Z committed Jun 14, 2022
1 parent a707d35 commit 47baa4e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 12 deletions.
11 changes: 0 additions & 11 deletions controllers/apps/emqx_handler.go
Original file line number Diff line number Diff line change
Expand Up @@ -197,17 +197,6 @@ func generateStatefulSetDef(instance appsv1beta3.Emqx) *appsv1.StatefulSet {
ReadinessProbe: instance.GetReadinessProbe(),
LivenessProbe: instance.GetLivenessProbe(),
StartupProbe: instance.GetStartupProbe(),
Lifecycle: &corev1.Lifecycle{
PreStop: &corev1.LifecycleHandler{
Exec: &corev1.ExecAction{
Command: []string{
"/opt/emqx/bin/emqx_ctl",
"cluster",
"leave",
},
},
},
},
},
},
},
Expand Down
2 changes: 1 addition & 1 deletion deploy/charts/emqx-operator/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 1.0.5
version: 1.0.6

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand Down

0 comments on commit 47baa4e

Please sign in to comment.