apps(publicfiles) Added publicfiles to the deployment
This commit is contained in:
4
apps/publicfiles/Caddyfile
Normal file
4
apps/publicfiles/Caddyfile
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
http://publicfiles.default.svc.yakumo.prettysunflower.moe, http://files.prettysunflower.moe {
|
||||||
|
root * /srv
|
||||||
|
file_server browse
|
||||||
|
}
|
35
apps/publicfiles/deployment.yaml
Normal file
35
apps/publicfiles/deployment.yaml
Normal file
@@ -0,0 +1,35 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: publicfiles
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: publicfiles
|
||||||
|
spec:
|
||||||
|
replicas: 3
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app.kubernetes.io/name: publicfiles
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: publicfiles
|
||||||
|
spec:
|
||||||
|
volumes:
|
||||||
|
- name: publicfiles
|
||||||
|
persistentVolumeClaim:
|
||||||
|
claimName: publicfiles
|
||||||
|
- name: config
|
||||||
|
configMap:
|
||||||
|
name: publicfiles-caddy-config
|
||||||
|
containers:
|
||||||
|
- image: caddy:latest
|
||||||
|
name: caddy
|
||||||
|
imagePullPolicy: Always
|
||||||
|
ports:
|
||||||
|
- containerPort: 80
|
||||||
|
protocol: TCP
|
||||||
|
volumeMounts:
|
||||||
|
- name: publicfiles
|
||||||
|
mountPath: "/srv"
|
||||||
|
- name: config
|
||||||
|
mountPath: /etc/caddy
|
8
apps/publicfiles/kustomization.yaml
Normal file
8
apps/publicfiles/kustomization.yaml
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
resources:
|
||||||
|
- deployment.yaml
|
||||||
|
- pvc.yaml
|
||||||
|
- services.yaml
|
||||||
|
configMapGenerator:
|
||||||
|
- name: publicfiles-caddy-config
|
||||||
|
files:
|
||||||
|
- Caddyfile
|
43
apps/publicfiles/pvc.yaml
Normal file
43
apps/publicfiles/pvc.yaml
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolume
|
||||||
|
metadata:
|
||||||
|
name: publicfiles
|
||||||
|
spec:
|
||||||
|
storageClassName: s3yuyuko
|
||||||
|
capacity:
|
||||||
|
storage: 10T
|
||||||
|
accessModes:
|
||||||
|
- ReadOnlyMany
|
||||||
|
claimRef:
|
||||||
|
namespace: default
|
||||||
|
name: publicfiles
|
||||||
|
csi:
|
||||||
|
driver: ru.yandex.s3.csi
|
||||||
|
controllerPublishSecretRef:
|
||||||
|
name: csi-yuyuko-secret
|
||||||
|
namespace: kube-system
|
||||||
|
nodePublishSecretRef:
|
||||||
|
name: csi-yuyuko-secret
|
||||||
|
namespace: kube-system
|
||||||
|
nodeStageSecretRef:
|
||||||
|
name: csi-yuyuko-secret
|
||||||
|
namespace: kube-system
|
||||||
|
volumeAttributes:
|
||||||
|
capacity: 10Ti
|
||||||
|
mounter: geesefs
|
||||||
|
options: --memory-limit 1000 --dir-mode 0777 --file-mode 0666
|
||||||
|
volumeHandle: publicfiles
|
||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: PersistentVolumeClaim
|
||||||
|
metadata:
|
||||||
|
name: publicfiles
|
||||||
|
spec:
|
||||||
|
storageClassName: "s3yuyuko"
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 10Ti
|
||||||
|
volumeMode: Filesystem
|
||||||
|
accessModes:
|
||||||
|
- ReadOnlyMany
|
||||||
|
volumeName: publicfiles
|
13
apps/publicfiles/services.yaml
Normal file
13
apps/publicfiles/services.yaml
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: publicfiles
|
||||||
|
spec:
|
||||||
|
type: ClusterIP
|
||||||
|
selector:
|
||||||
|
app.kubernetes.io/name: publicfiles
|
||||||
|
ports:
|
||||||
|
- protocol: TCP
|
||||||
|
port: 80
|
||||||
|
targetPort: 80
|
||||||
|
name: http
|
Reference in New Issue
Block a user