Skip to content

Commit

Permalink
add config volume
Browse files Browse the repository at this point in the history
  • Loading branch information
Romanow committed Apr 16, 2024
1 parent 6dcffed commit eb27aa1
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 2 deletions.
2 changes: 1 addition & 1 deletion charts/java-service/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
name: java-service
type: application
description: Helm chart for Spring Boot application with logging and tracing
version: 1.5.1
version: 1.5.2
appVersion: "v1.0"
home: https://github.com/Romanow/helm-charts/tree/master/charts/java-service
icon: https://raw.githubusercontent.com/Romanow/helm-charts/master/icons/spring-boot.png
Expand Down
11 changes: 10 additions & 1 deletion charts/java-service/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Helm Chart for java-service

![Version: 1.5.1](https://img.shields.io/badge/Version-1.5.1-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v1.0](https://img.shields.io/badge/AppVersion-v1.0-informational?style=flat-square)
![Version: 1.5.2](https://img.shields.io/badge/Version-1.5.2-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v1.0](https://img.shields.io/badge/AppVersion-v1.0-informational?style=flat-square)

Helm chart for Spring Boot application with logging and tracing

Expand Down Expand Up @@ -41,6 +41,15 @@ false
</td>
<td>Enable circuit breaker (set `CIRCUIT_BREAKER_ENABLED` env)</td>
</tr>
<tr>
<td>configVolumes</td>
<td>list</td>
<td><pre lang="json">
[]
</pre>
</td>
<td>External configs</td>
</tr>
<tr>
<td>database.host</td>
<td>string</td>
Expand Down
13 changes: 13 additions & 0 deletions charts/java-service/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -119,10 +119,23 @@ spec:
- name: {{ .Chart.Name }}-config-volume
mountPath: /usr/share/filebeat/filebeat.yml
subPath: filebeat.yml
{{- range $config := .Values.configVolumes }}
- name: {{ $config.name }}-config-volume
mountPath: {{ $config.mount }}
{{- if $config.path }}
subPath: {{ $config.path }}
{{- end }}
{{- end }}
{{- end }}
volumes:
- name: {{ .Chart.Name }}-logs-volume
- name: {{ .Chart.Name }}-config-volume
configMap:
name: {{ .Release.Name }}
defaultMode: 420
{{- range $config := .Values.configVolumes }}
- name: {{ $config.name }}
configMap:
name: {{ $config.name }}-config-volume
defaultMode: 420
{{- end }}
3 changes: 3 additions & 0 deletions charts/java-service/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@ environments: []
# -- Additional secrets
secrets: []

# -- External configs
configVolumes: []

# -- Count of replicas
replicas: 1
ports:
Expand Down

0 comments on commit eb27aa1

Please sign in to comment.