Skip to content

Commit 48e47cc

Browse files
authored
support podlabels (#29)
Fixes #28
1 parent 33e4c2c commit 48e47cc

File tree

13 files changed

+89
-13
lines changed

13 files changed

+89
-13
lines changed

.github/helm-docs.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/bin/bash
22
set -euo pipefail
33

4-
HELM_DOCS_VERSION="1.13.0"
4+
HELM_DOCS_VERSION="1.13.1"
55

66
# install helm-docs
77
curl --silent --show-error --fail --location --output /tmp/helm-docs.tar.gz https://github.com/norwoodj/helm-docs/releases/download/v"${HELM_DOCS_VERSION}"/helm-docs_"${HELM_DOCS_VERSION}"_Linux_x86_64.tar.gz

README.adoc

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ https://artifacthub.io/packages/search?repo=featurehub[image:https://img.shields
66

77
== Deploying FeatureHub on Kubernetes
88

9-
Helm chart is designed to support FeatureHub's most scalable deployment option (REST + Streaming real-time feature updates). Read more about it https://docs.featurehub.io/featurehub/1.7.2/installation.html#_option_2a_scalable_deployment_streaming_rest_feature_updates[here]
9+
Helm chart is designed to support FeatureHub's most scalable deployment option (REST + Streaming real-time feature updates). Read more about it https://docs.featurehub.io/featurehub/1.7.2/installation.html#_option_2a_scalable_deployment_streaming_rest_feature_updates[here]
1010

1111
These instructions are designed to get you up and running on a local kubernetes running on KinD. They will be
1212
fleshed out over time as we have these examples running on Google's GKE/Autopilot, AWS's EKS/Fargate, and Azure's
@@ -122,7 +122,7 @@ get a service endpoint for it). For example:
122122

123123
$ kubectl get pods
124124

125-
and then port-forward
125+
and then port-forward
126126

127127
The management port is exposed on a service:
128128

@@ -140,6 +140,9 @@ out exactly what is wrong, and so should the endpoint.
140140

141141
== Changelog [[changelog]]
142142

143+
=== 4.1.3
144+
- support for global and perdeployment podlabels
145+
143146
=== 4.1.0
144147
- support Google Pub/Sub configuration (including local dev)
145148
- clearly delineate application params vs env var based deployment

helm/featurehub/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ description: "FeatueHub is an Enterprise Grade, Cloud Native Feature Management
1212
their own requirements.
1313
"
1414
type: application
15-
version: 4.1.2
15+
version: 4.1.3
1616
icon: https://raw.githubusercontent.com/featurehub-io/featurehub/main/docs/modules/ROOT/images/fh_icon.png
17-
appVersion: "1.7.0"
17+
appVersion: "1.7.1"
1818
maintainers:
1919
- name: FeatureHub
2020
email: info@featurehub.io

helm/featurehub/README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# featurehub
22

3-
![Version: 4.1.2](https://img.shields.io/badge/Version-4.1.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.7.0](https://img.shields.io/badge/AppVersion-1.7.0-informational?style=flat-square)
3+
![Version: 4.1.3](https://img.shields.io/badge/Version-4.1.3-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: 1.7.1](https://img.shields.io/badge/AppVersion-1.7.1-informational?style=flat-square)
44

55
FeatueHub is an Enterprise Grade, Cloud Native Feature Management platform that is available to suite any organisations requirements. This fully supported Helm chart is the Open Source version of the product, which has all the same features as the [SaaS product](https://app.featurehub.io).
66

@@ -50,6 +50,7 @@ NATS and Postgres are *NOT* requirements of the project and are included only fo
5050
| dacha.podAnnotations | object | `{}` | |
5151
| dacha.podDisruptionBudget.enabled | bool | `true` | |
5252
| dacha.podDisruptionBudget.maxUnavailable | int | `1` | |
53+
| dacha.podLabels | object | `{}` | this allows you to specify pod labels that will appear on dacha deployments |
5354
| dacha.podSecurityContext.fsGroup | int | `999` | |
5455
| dacha.prometheus | object | `{"enabled":false,"labels":{}}` | Prometheus configuration |
5556
| dacha.prometheus.enabled | bool | `false` | Whether to enable or disable prometheus metrics endpoints, and serviceMonitor If enabled, metrics are exposed on port 8701, on /metrics endpoint |
@@ -95,6 +96,7 @@ NATS and Postgres are *NOT* requirements of the project and are included only fo
9596
| edge.podAnnotations | object | `{}` | |
9697
| edge.podDisruptionBudget.enabled | bool | `true` | |
9798
| edge.podDisruptionBudget.maxUnavailable | int | `1` | |
99+
| edge.podLabels | object | `{}` | this allows you to specify pod labels that will appear on edge deployments |
98100
| edge.podSecurityContext.fsGroup | int | `999` | |
99101
| edge.prometheus | object | `{"enabled":false,"labels":{}}` | Prometheus configuration |
100102
| edge.prometheus.enabled | bool | `false` | Whether to enable or disable prometheus metrics endpoints, and serviceMonitor If enabled, metrics are exposed on port 8701, on /metrics endpoint |
@@ -125,6 +127,7 @@ NATS and Postgres are *NOT* requirements of the project and are included only fo
125127
| global.ingress.enabled | bool | `true` | |
126128
| global.ingress.ingressClassName | string | `""` | specify the ingress class name if thats what makes yor ingress work. E.g. in AWS its "alb" |
127129
| global.intranet | bool | `false` | if set to true, then MR will serve the intranet version of the application which does not require external HTML dependencies |
130+
| global.podLabels | object | `{}` | this allows you to specify pod labels that will appear on all deployments |
128131
| global.urlPath | string | `""` | the default url path is to mount as root, this lets you mount where ever you like, but it affects the health checks |
129132
| googlepubsub.backOffInSeconds | int | `20` | how long to backoff when failing to process a request from an incoming subscription |
130133
| googlepubsub.channels | object | `{"edgemr":{"description":"Updates from Edge are published through this channel and picked up by MR","subscription":"enricher-updates-sub","topicName":"featurehub-edge-updates"},"enrichedEvents":{"topicName":"enriched-feature-data"},"featureChangeMessage":{"description":"this is issued when a feature has changed, it is a complex diff message. It may or may not be enabled","topicName":"featurehub-messaging-channel"},"featureEnricher":{"description":"This channel is used for the initial enriched events. It is a queue.","subscription":"enricher-updates-sub","topicName":"enricher-updates-sub"},"featureWebhook":{"description":"dacha broadcasts to the topic, edge listens","subscription":"featurehub-enriched-events","topicName":"featurehub-enriched-events-webhooks"},"mrdacha":{"dachaPrefix":"featurehub-dacha2-listener","topicName":"featurehub-mr-dacha2"},"mredge":{"edgePrefix":"featurehub-edge-listener","topicName":"featurehub-mr-edge"},"stats":{"topicName":"featurehub-stats"}}` | feed these from something like Terraform, Pulumi or a Crossplane XRD. For more details see [PubSub config docs](https://docs.featurehub.io/featurehub/latest/configuration.html#_googles_pubsub) |
@@ -161,6 +164,7 @@ NATS and Postgres are *NOT* requirements of the project and are included only fo
161164
| managementRepository.podAnnotations | object | `{}` | |
162165
| managementRepository.podDisruptionBudget.enabled | bool | `true` | |
163166
| managementRepository.podDisruptionBudget.maxUnavailable | int | `1` | |
167+
| managementRepository.podLabels | object | `{}` | this allows you to specify pod labels that will appear on MR deployments |
164168
| managementRepository.podSecurityContext.fsGroup | int | `999` | |
165169
| managementRepository.prometheus | object | `{"enabled":false,"labels":{}}` | Prometheus configuration |
166170
| managementRepository.prometheus.enabled | bool | `false` | Whether to enable or disable prometheus metrics endpoints, and serviceMonitor If enabled, metrics are exposed on port 8701, on /metrics endpoint |
@@ -181,6 +185,3 @@ NATS and Postgres are *NOT* requirements of the project and are included only fo
181185
| nats | object | `{"cluster":{"enabled":true,"name":"featurehub","replicas":3},"enabled":true,"topologyKeys":[]}` | ----------------------------------------------------------------------------- # |
182186
| podAnnotations | object | `{}` | |
183187
| postgresql | object | `{"enabled":true,"global":{"postgresql":{"auth":{"postgresPassword":"postgresql"}}},"primary":{"initdb":{"scripts":{"featurehub.sql":"CREATE USER featurehub PASSWORD 'featurehub' LOGIN;\nCREATE DATABASE featurehub;\nGRANT ALL PRIVILEGES ON DATABASE featurehub TO featurehub;\n\\connect featurehub\nGRANT ALL ON SCHEMA public TO featurehub;"}},"persistence":{"accessModes":["ReadWriteOnce"],"enabled":true,"size":"128Mi","storageClassName":"standard"}}}` | ----------------------------------------------------------------------------- # |
184-
185-
----------------------------------------------
186-
Autogenerated from chart metadata using [helm-docs v1.13.0](https://github.com/norwoodj/helm-docs/releases/v1.13.0)

helm/featurehub/README.md.gotmpl

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{{ template "chart.header" . }}
2+
{{ template "chart.deprecationWarning" . }}
3+
4+
{{ template "chart.badgesSection" . }}
5+
6+
{{ template "chart.description" . }}
7+
8+
{{ template "chart.homepageLine" . }}
9+
10+
{{ template "chart.maintainersSection" . }}
11+
12+
{{ template "chart.sourcesSection" . }}
13+
14+
{{ template "chart.requirementsSection" . }}
15+
16+
{{ template "chart.valuesSection" . }}

helm/featurehub/templates/_helpers.tpl

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,18 @@ Create the name of the service account to use (dacha)
133133
{{- end }}
134134
{{- end }}
135135

136+
{{- define "featurehub.podlabels" -}}
137+
{{- range $key, $value := . -}}
138+
{{ $key | quote }}: {{ $value | quote }}
139+
{{- end -}}
140+
{{- end -}}
141+
142+
{{- define "featurehub.globalPodlabels" -}}
143+
{{- range $key, $value := .Values.global.podLabels -}}
144+
{{ $key | quote }}: {{ $value | quote }}
145+
{{- end -}}
146+
{{- end -}}
147+
136148
{{/*This allows us to have an override location*/}}
137149
{{- define "featurehub.liveness.url" -}}
138150
{{- if ne .Values.global.urlPath "" }}

helm/featurehub/templates/dacha/deployment.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ spec:
4545
{{- end }}
4646
labels:
4747
{{- include "featurehub.dacha.selectorLabels" . | nindent 8 }}
48+
{{- include "featurehub.podlabels" .Values.dacha.podLabels | nindent 8 }}
49+
{{- include "featurehub.globalPodlabels" . | nindent 8 }}
4850
spec:
4951
{{- with .Values.dacha.imagePullSecrets }}
5052
imagePullSecrets:

helm/featurehub/templates/edge/deployment.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ spec:
4545
{{- end }}
4646
labels:
4747
{{- include "featurehub.edge.selectorLabels" . | nindent 8 }}
48+
{{- include "featurehub.podlabels" .Values.edge.podLabels | nindent 8 }}
49+
{{- include "featurehub.globalPodlabels" . | nindent 8 }}
4850
spec:
4951
{{- with .Values.imagePullSecrets }}
5052
imagePullSecrets:

helm/featurehub/templates/management-repository/deployment.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,8 @@ spec:
4545
{{- end }}
4646
labels:
4747
{{- include "featurehub.managementRepository.selectorLabels" . | nindent 8 }}
48+
{{- include "featurehub.podlabels" .Values.managementRepository.podLabels | nindent 8 }}
49+
{{- include "featurehub.globalPodlabels" . | nindent 8 }}
4850
spec:
4951
{{- with .Values.imagePullSecrets }}
5052
imagePullSecrets:

helm/featurehub/values.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,9 @@ global:
2828
# Entries of the secret specified here are the same as would be specified in /etc/app-config/secrets.properties
2929
envFromSecret: ""
3030

31+
# -- this allows you to specify pod labels that will appear on all deployments
32+
podLabels: {}
33+
3134
# This is only used for the short-cut KinD ingress, you would not use this in your own cluster
3235
ingress:
3336
enabled: true
@@ -112,6 +115,9 @@ managementRepository:
112115
strategy: {}
113116
# type: RollingUpdate
114117

118+
# -- this allows you to specify pod labels that will appear on MR deployments
119+
podLabels: {}
120+
115121
image:
116122
repository: featurehub/mr
117123
tag: ""
@@ -303,6 +309,9 @@ edge:
303309
strategy: {}
304310
# type: RollingUpdate
305311

312+
# -- this allows you to specify pod labels that will appear on edge deployments
313+
podLabels: {}
314+
306315
image:
307316
repository: featurehub/edge
308317
tag: ""
@@ -475,6 +484,9 @@ dacha:
475484
strategy: {}
476485
# type: RollingUpdate
477486

487+
# -- this allows you to specify pod labels that will appear on dacha deployments
488+
podLabels: {}
489+
478490
# -- If `true`, entries from `environmentVars` will be mapped to /etc/app-config/application.properties file
479491
# To mount secret settings as /etc/app-config/application.properties see volume fields
480492
# Used for retrocompatiblity with FeatureHub controller versions lower than 1.5.0

0 commit comments

Comments
 (0)