91 lines
1.9 KiB
YAML
91 lines
1.9 KiB
YAML
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: adguard-service
|
|
namespace: adguard
|
|
spec:
|
|
selector:
|
|
app: adguard
|
|
ports:
|
|
- port: 3000
|
|
name: webui
|
|
targetPort: 3000
|
|
- port: 53
|
|
name: dns
|
|
targetPort: 53
|
|
protocol: UDP
|
|
- port: 53
|
|
name: dns-tcp
|
|
targetPort: 53
|
|
protocol: TCP
|
|
- port: 853
|
|
name: dot
|
|
targetPort: 853
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: adguard-deployment
|
|
namespace: adguard
|
|
spec:
|
|
replicas: 1
|
|
selector:
|
|
matchLabels:
|
|
app: adguard
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: adguard
|
|
spec:
|
|
containers:
|
|
- name: adguard
|
|
image: adguard/adguardhome:latest
|
|
resources:
|
|
limits:
|
|
memory: "1Gi"
|
|
cpu: "500m"
|
|
requests:
|
|
memory: "128Mi"
|
|
cpu: "50m"
|
|
ports:
|
|
- containerPort: 3000
|
|
name: webui
|
|
- containerPort: 53
|
|
name: dns
|
|
- containerPort: 853
|
|
name: dot
|
|
volumeMounts:
|
|
- name: adguard-data
|
|
mountPath: /opt/adguardhome/work
|
|
subPath: work
|
|
- name: adguard-data
|
|
mountPath: /opt/adguardhome/conf
|
|
subPath: conf
|
|
- name: adguard-certs
|
|
mountPath: /certs
|
|
readOnly: true
|
|
volumes:
|
|
- name: adguard-data
|
|
persistentVolumeClaim:
|
|
claimName: adguard-pvc
|
|
- name: adguard-certs
|
|
secret:
|
|
secretName: adguard-certs
|
|
items:
|
|
- key: tls.crt
|
|
path: fullchain.pem
|
|
- key: tls.key
|
|
path: privkey.pem
|
|
---
|
|
apiVersion: v1
|
|
kind: PersistentVolumeClaim
|
|
metadata:
|
|
name: adguard-pvc
|
|
namespace: adguard
|
|
spec:
|
|
accessModes:
|
|
- ReadWriteOnce
|
|
resources:
|
|
requests:
|
|
storage: 2Gi
|