Skip to content

Commit

Permalink
Improvements to kubetail chart
Browse files Browse the repository at this point in the history
* Removed `namespace` definition from ClusterRole
* Set default name of workloads to release-name
  • Loading branch information
amorey committed Feb 11, 2024
1 parent 5e400ff commit 050456a
Show file tree
Hide file tree
Showing 8 changed files with 13 additions and 14 deletions.
2 changes: 1 addition & 1 deletion charts/kubetail/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ keywords:
- kubetail
- logging
type: application
version: 0.1.0
version: 0.1.1
appVersion: "0.1.0"
home: https://github.com/kubetail-org/kubetail
maintainers:
Expand Down
2 changes: 1 addition & 1 deletion charts/kubetail/templates/cluster-role-binding.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:
name: {{ .Values.clusterRoleBinding.name }}
name: {{ if .Values.clusterRoleBinding.name }}{{ .Values.clusterRoleBinding.name }}{{ else }}{{ include "kubetail.fullname" . }}{{ end }}
labels:
{{- include "kubetail.labels" $ | nindent 4 }}
roleRef:
Expand Down
3 changes: 1 addition & 2 deletions charts/kubetail/templates/cluster-role.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:
{{- include "kubetail.metadataNamespace" $ | nindent 2 }}
name: {{ .Values.clusterRole.name }}
name: {{ if .Values.clusterRole.name }}{{ .Values.clusterRole.name }}{{ else }}{{ include "kubetail.fullname" . }}{{ end }}
labels:
{{- include "kubetail.labels" $ | nindent 4 }}
{{- with .Values.clusterRoleBinding.rules }}
Expand Down
2 changes: 1 addition & 1 deletion charts/kubetail/templates/config-map.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ kind: ConfigMap
apiVersion: v1
metadata:
{{- include "kubetail.metadataNamespace" $ | nindent 2 }}
name: {{ .Values.configMap.name }}
name: {{ if .Values.configMap.name }}{{ .Values.configMap.name }}{{ else }}{{ include "kubetail.fullname" . }}{{ end }}
labels:
{{- include "kubetail.labels" $ | nindent 4 }}
data:
Expand Down
2 changes: 1 addition & 1 deletion charts/kubetail/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ kind: Deployment
apiVersion: apps/v1
metadata:
{{- include "kubetail.metadataNamespace" $ | nindent 2 }}
name: {{ .Values.deployment.name }}
name: {{ if .Values.deployment.name }}{{ .Values.deployment.name }}{{ else }}{{ include "kubetail.fullname" . }}{{ end }}
labels:
{{- include "kubetail.labels" $ | nindent 4 }}
spec:
Expand Down
2 changes: 1 addition & 1 deletion charts/kubetail/templates/service-account.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@ apiVersion: v1
kind: ServiceAccount
metadata:
{{- include "kubetail.metadataNamespace" $ | nindent 2 }}
name: {{ .Values.serviceAccount.name }}
name: {{ if .Values.serviceAccount.name }}{{ .Values.serviceAccount.name }}{{ else }}{{ include "kubetail.fullname" . }}{{ end }}
labels:
{{- include "kubetail.labels" $ | nindent 4 }}
2 changes: 1 addition & 1 deletion charts/kubetail/templates/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ kind: Service
apiVersion: v1
metadata:
{{- include "kubetail.metadataNamespace" $ | nindent 2 }}
name: {{ .Values.service.name }}
name: {{ if .Values.service.name }}{{ .Values.service.name }}{{ else }}{{ include "kubetail.fullname" . }}{{ end }}
labels:
{{- include "kubetail.labels" $ | nindent 4 }}
spec:
Expand Down
12 changes: 6 additions & 6 deletions charts/kubetail/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,11 @@ image:

# cluster-role options
clusterRole:
name: kubetail-cr
name:

# cluster-role-binding options
clusterRoleBinding:
name: kubetail-crb
name:
rules:
- apiGroups:
- ""
Expand All @@ -53,11 +53,11 @@ clusterRoleBinding:

# configMap options
configMap:
name: kubetail-cfg
name:

# deployment options
deployment:
name: kubetail
name:
replicas: 1
revisionHistoryLimit: 10
updateStrategy: {}
Expand All @@ -80,13 +80,13 @@ deployment:

# service options
service:
name: kubetail
name:
type: ClusterIP
port: 4000

# service-account options
serviceAccount:
name: kubetail-sa
name:

# kubetail config
config:
Expand Down

0 comments on commit 050456a

Please sign in to comment.