Skip to content

Commit

Permalink
chore: Add flag to create or disable chaos daemon (#89)
Browse files Browse the repository at this point in the history
  • Loading branch information
miketonks-form3 committed Aug 29, 2024
1 parent c9865b5 commit 37ad69b
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 2 deletions.
3 changes: 2 additions & 1 deletion helm/chaos-mesh/templates/chaos-daemon-daemonset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#

{{- if .Values.chaosDaemon.create }}
apiVersion: apps/v1
kind: DaemonSet
metadata:
Expand Down Expand Up @@ -213,3 +213,4 @@ spec:
tolerations:
{{ toYaml . | indent 8 }}
{{- end }}
{{- end }}
2 changes: 2 additions & 0 deletions helm/chaos-mesh/templates/chaos-daemon-rbac.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
{{- if .Values.chaosDaemon.create }}
{{- if .Values.chaosDaemon.serviceAccount }}
---
kind: ServiceAccount
Expand Down Expand Up @@ -132,4 +133,5 @@ spec:
- secret
- hostPath
{{- end }}
{{- end }}

2 changes: 2 additions & 0 deletions helm/chaos-mesh/templates/chaos-daemon-service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
{{- if .Values.chaosDaemon.create }}
apiVersion: v1
kind: Service
metadata:
Expand Down Expand Up @@ -43,3 +44,4 @@ spec:
selector:
{{- include "chaos-mesh.selectors" . | nindent 4 }}
app.kubernetes.io/component: chaos-daemon
{{- end }}
2 changes: 2 additions & 0 deletions helm/chaos-mesh/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,8 @@ controllerManager:
type: DirectoryOrCreate

chaosDaemon:
# Enable chaos-daemon
create: true
# image would be constructed by <registry>/<repository>:<tag>
image:
# override global registry, empty value means using the global images.registry
Expand Down
1 change: 0 additions & 1 deletion install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1622,7 +1622,6 @@ spec:
# See the License for the specific language governing permissions and
# limitations under the License.
#
apiVersion: apps/v1
kind: DaemonSet
metadata:
Expand Down

0 comments on commit 37ad69b

Please sign in to comment.