1
0
Fork 0
home-stack-kustomize/kustomize/bases/nextcloud/nextcloud-deployment.yaml

99 lines
2.2 KiB
YAML
Raw Normal View History

2020-05-02 01:55:34 +00:00
apiVersion: apps/v1
kind: Deployment
metadata:
2020-05-18 20:18:39 +00:00
name: nextcloud
2020-05-02 01:55:34 +00:00
labels:
2021-08-26 16:42:32 +00:00
app.kubernetes.io/name: nextcloud
2020-05-02 01:55:34 +00:00
spec:
selector:
matchLabels:
2021-08-26 16:42:32 +00:00
app.kubernetes.io/name: nextcloud
2020-05-02 01:55:34 +00:00
template:
metadata:
labels:
2021-08-26 16:42:32 +00:00
app.kubernetes.io/name: nextcloud
2020-05-02 01:55:34 +00:00
spec:
containers:
- name: nextcloud
2020-08-29 04:54:40 +00:00
image: nextcloud:19.0.2
2020-05-02 01:55:34 +00:00
env:
- name: TRUSTED_PROXIES
value: 10.0.0.0/8
2021-08-26 16:42:10 +00:00
- name: POSTGRES_HOST
2020-08-11 04:37:20 +00:00
valueFrom:
secretKeyRef:
2021-08-26 16:42:10 +00:00
name: postgres-credentials-secret
2020-08-11 04:37:20 +00:00
key: host
2021-08-26 16:42:10 +00:00
- name: POSTGRES_DATABASE
2020-05-02 01:55:34 +00:00
valueFrom:
secretKeyRef:
2021-08-26 16:42:10 +00:00
name: postgres-credentials-secret
2020-05-02 01:55:34 +00:00
key: database
2021-08-26 16:42:10 +00:00
- name: POSTGRES_USER
2020-05-02 01:55:34 +00:00
valueFrom:
secretKeyRef:
2021-08-26 16:42:10 +00:00
name: postgres-credentials-secret
2020-05-02 01:55:34 +00:00
key: username
2021-08-26 16:42:10 +00:00
- name: POSTGRES_PASSWORD
2020-05-02 01:55:34 +00:00
valueFrom:
secretKeyRef:
2021-08-26 16:42:10 +00:00
name: postgres-credentials-secret
2020-05-02 01:55:34 +00:00
key: password
ports:
- name: http
containerPort: 80
volumeMounts:
2020-08-29 04:54:40 +00:00
- name: nextcloud-data
2020-05-02 01:55:34 +00:00
mountPath: /var/www/html
volumes:
2020-08-29 04:54:40 +00:00
- name: nextcloud-data
2020-05-02 01:55:34 +00:00
persistentVolumeClaim:
2020-08-29 04:54:40 +00:00
claimName: nextcloud-data
---
apiVersion: v1
kind: PersistentVolume
metadata:
name: nextcloud-data-nfs
labels:
2021-08-26 16:42:32 +00:00
app.kubernetes.io/name: nextcloud
2020-08-29 04:54:40 +00:00
spec:
accessModes:
- ReadWriteMany
capacity:
storage: 100Mi
nfs:
server: nfs-localhost
path: /nextcloud
mountOptions: ["vers=4"]
2020-05-02 01:55:34 +00:00
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
2020-08-29 04:54:40 +00:00
name: nextcloud-data
2020-05-02 01:55:34 +00:00
labels:
2021-08-26 16:42:32 +00:00
app.kubernetes.io/name: nextcloud
2020-05-02 01:55:34 +00:00
spec:
2020-08-29 04:54:40 +00:00
storageClassName: ""
2020-05-02 01:55:34 +00:00
accessModes:
2020-08-29 04:54:40 +00:00
- ReadWriteMany
2020-05-02 01:55:34 +00:00
resources:
requests:
2020-08-29 04:54:40 +00:00
storage: 100Mi
selector:
matchLabels:
2021-08-26 16:42:32 +00:00
app.kubernetes.io/name: nextcloud
2020-05-02 01:55:34 +00:00
---
apiVersion: v1
kind: Service
metadata:
name: nextcloud
labels:
2021-08-26 16:42:32 +00:00
app.kubernetes.io/name: nextcloud
2020-05-02 01:55:34 +00:00
spec:
selector:
2021-08-26 16:42:32 +00:00
app.kubernetes.io/name: nextcloud
2020-05-02 01:55:34 +00:00
ports:
- name: http
protocol: TCP
port: 80
2020-08-02 03:40:27 +00:00
targetPort: http