-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[prometheus-push-gateway] Add lifecycle hooks (#5103)
* [prometheus-push-gateway] Add lifecycle hooks Fixes #5102 Add support for lifecycle hooks in the push-gateway deployment. * Add lifecycle hooks configuration to `charts/prometheus-pushgateway/templates/deployment.yaml` * Add lifecycle hooks configuration to `charts/prometheus-pushgateway/templates/statefulset.yaml` * Add lifecycle hooks configuration options in `charts/prometheus-pushgateway/values.yaml` Signed-off-by: Duncan Schulze <[email protected]> * address comments Signed-off-by: Duncan Schulze <[email protected]> * Correct placement of lifecycle Signed-off-by: zeritti <[email protected]> * Add CI test cases Signed-off-by: zeritti <[email protected]> --------- Signed-off-by: Duncan Schulze <[email protected]> Signed-off-by: zeritti <[email protected]> Co-authored-by: zeritti <[email protected]>
- Loading branch information
Showing
18 changed files
with
100 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 2 additions & 0 deletions
2
charts/prometheus-pushgateway/ci/automount-sa-token-values.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
--- | ||
automountServiceAccountToken: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# default sts values | ||
runAsStatefulSet: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# default values |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
--- | ||
extraArgs: | ||
- "--log.level=debug" |
19 changes: 19 additions & 0 deletions
19
charts/prometheus-pushgateway/ci/extramanifests-values.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
extraManifests: | ||
- apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
labels: | ||
foo: bar | ||
name: pushgateway-extra-cm-first | ||
data: | ||
FOO: "bar" | ||
- apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
labels: | ||
baz: qux | ||
name: pushgateway-extra-cm-second | ||
data: | ||
pushgateway.txt: '{{ include "prometheus-pushgateway.fullname" . }}' | ||
immutable: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
--- | ||
extraVars: | ||
- name: FOO | ||
value: bar |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
lifecycle: | ||
preStop: | ||
exec: | ||
command: ["/bin/sh", "-c", "sleep 10"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
runAsStatefulSet: true | ||
persistentVolume: | ||
enabled: true | ||
size: 1Gi | ||
|
||
persistentVolumeLabels: | ||
foo: bar | ||
baz: qux |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
--- | ||
persistentVolume: | ||
enabled: true | ||
size: 1Gi | ||
|
||
persistentVolumeLabels: | ||
foo: bar | ||
baz: qux |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
runAsStatefulSet: true | ||
podLabels: | ||
foo: bar | ||
baz: qux |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
--- | ||
podLabels: | ||
foo: bar | ||
baz: qux |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
--- | ||
resources: | ||
requests: | ||
cpu: 50m | ||
memory: 32Mi | ||
limits: | ||
cpu: 100m | ||
memory: 32Mi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
containerSecurityContext: | ||
allowPrivilegeEscalation: false | ||
capabilities: | ||
drop: | ||
- ALL | ||
readOnlyRootFilesystem: true | ||
seccompProfile: | ||
type: RuntimeDefault |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
--- | ||
serviceLabels: | ||
foo: bar | ||
baz: qux |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
serviceMonitor: | ||
enabled: true | ||
namespace: null | ||
interval: 15s | ||
additionalLabels: | ||
release: prometheus |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters