Skip to content

Add label support to the data-pvc #55

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion charts/factorio-server-charts/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ sources:
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 2.0.1
version: 2.0.2

# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
Expand Down
1 change: 1 addition & 0 deletions charts/factorio-server-charts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,7 @@ If you do run into any issues with mods, I will try to work with you on finding
| `persistence.dataDir.existingClaim` | The name of an existing PVC to use for persistence | |
| `persistence.storageClassName` | Persistent Volume storage class | `""` |
| `persistence.annotations` | Persistent Volume Claim annotations | `{}` |
| `persistence.lables` | Persistent Volume Claim labels | `{}` |

### Factorio Parameters

Expand Down
3 changes: 3 additions & 0 deletions charts/factorio-server-charts/templates/datadir-pvc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ metadata:
name: {{ template "factorio-server-charts.fullname" . }}-datadir
labels:
app: "{{ template "factorio-server-charts.fullname" . }}-{{ .Chart.Version }}"
{{- if .Values.persistence.labels }}
{{ toYaml .Values.persistence.labels | indent 4 }}
{{- end }}
{{- if .Values.persistence.annotations }}
annotations:
{{ toYaml .Values.persistence.annotations | indent 4 }}
Expand Down
3 changes: 3 additions & 0 deletions charts/factorio-server-charts/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ affinity: {}
## @extra persistence.dataDir.existingClaim The name of an existing PVC to use for persistence
## @param persistence.storageClassName Persistent Volume storage class
## @param persistence.annotations Persistent Volume Claim annotations
## @param persistence.labels Persistent Volume Claim labels
## Sets the data persistence volume configuration
## IMPORTANT: If you do not setup a PV all your savegames will be lost on pod recreation or helm upgrade
persistence:
Expand All @@ -118,6 +119,8 @@ persistence:
storageClassName: ""
## If you have annotations to spin up a PV i.e. the location. Remove the curly braces
annotations: {}
## If you have additional labels to apply to the volume
labels: {}


#### Factorio application configuration ####
Expand Down
Loading