Skip to content

Commit

Permalink
Convert to single-replica STS
Browse files Browse the repository at this point in the history
  • Loading branch information
drewburr committed Aug 25, 2024
1 parent 6817b29 commit 45ca6e9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
8 changes: 3 additions & 5 deletions charts/minecraft-server/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
apiVersion: apps/v1
kind: Deployment
kind: StatefulSet
metadata:
name: {{ include "minecraft-server.fullname" . }}
labels:
{{- include "minecraft-server.labels" . | nindent 4 }}
spec:
{{- if not .Values.autoscaling.enabled }}
replicas: {{ .Values.replicaCount }}
{{- end }}
replicas: 1
selector:
matchLabels:
{{- include "minecraft-server.selectorLabels" . | nindent 6 }}
Expand All @@ -28,7 +26,7 @@ spec:
securityContext:
{{- toYaml .Values.podSecurityContext | nindent 8 }}
containers:
- name: {{ .Chart.Name }}
- name: minecraft-server
securityContext:
{{- toYaml .Values.securityContext | nindent 12 }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
Expand Down
2 changes: 0 additions & 2 deletions charts/minecraft-server/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
# This is a YAML-formatted file.
# Declare variables to be passed into your templates.

replicaCount: 1

image:
repository: nginx
pullPolicy: IfNotPresent
Expand Down

0 comments on commit 45ca6e9

Please sign in to comment.