add unzip and copy properties init container, don't mount properties
This commit is contained in:
@@ -14,27 +14,36 @@ spec:
|
||||
app: {{ .Release.Name }}
|
||||
spec:
|
||||
initContainers:
|
||||
- name: get-version
|
||||
image: {{ .Values.get_server.image }}
|
||||
imagePullPolicy: Always
|
||||
env:
|
||||
- name: SERVER_VERSION
|
||||
value: {{ .Values.server_version }}
|
||||
volumeMounts:
|
||||
- mountPath: /downloads
|
||||
name: data
|
||||
containers:
|
||||
- name: {{ .Release.Name }}
|
||||
- name: unzip
|
||||
image: {{ .Values.image }}
|
||||
imagePullPolicy: Always
|
||||
command: ["/bin/bash"]
|
||||
args: ["-c", "unzip -n -d . /the-1122-pack/the-1122-pack_1.3.7.zip"]
|
||||
volumeMounts:
|
||||
- mountPath: /mc_data
|
||||
name: data
|
||||
- name: copy-properties
|
||||
image: debian:latest
|
||||
imagePullPolicy: Always
|
||||
command: ["/bin/bash"]
|
||||
args: ["-c", "cp -f /server.properties /mc_data/server.properties"]
|
||||
volumeMounts:
|
||||
- mountPath: /mc_data
|
||||
name: data
|
||||
- name: properties
|
||||
mountPath: /server.properties
|
||||
subPath: server.properties
|
||||
containers:
|
||||
- name: server
|
||||
image: {{ .Values.image }}
|
||||
imagePullPolicy: Always
|
||||
command: ["/bin/bash"]
|
||||
args: ["-c", 'java -server -Xmx"$MAX_RAM"G -Dfml.queryResult=confirm -jar forge-1.12.2-14.23.5.2855.jar nogui']
|
||||
ports:
|
||||
- containerPort: 25565
|
||||
volumeMounts:
|
||||
- mountPath: /mc_data
|
||||
name: data
|
||||
- name: properties
|
||||
mountPath: /mc_data/server.properties
|
||||
subPath: server.properties
|
||||
- name: properties
|
||||
mountPath: /mc_data/eula.txt
|
||||
subPath: eula.txt
|
||||
|
||||
Reference in New Issue
Block a user