* backend: k8s: - support crawls with multiple wacz files, don't assume crawl complete after first wacz uploaded - if crawl is running and has wacz file, still show as running - k8s: allow configuring node selector for main pods (eg. nodeType=main) and for crawlers (eg. nodeType=crawling) - profiles: support uploading to alternate storage specified via 'shared_profile_storage' value is set - misc fixes for profiles * backend: ensure docker run_profile api matches k8s k8s chart: don't delete pvc and pv in helm chart * dependency: bump authsign to 0.4.0 docker: disable public redis port * profiles: fix path, profile browser return value * fix typo in presigned url cacheing
143 lines
2.7 KiB
YAML
143 lines
2.7 KiB
YAML
|
|
# mongo secrets used with backend and with local mongo, if any
|
|
|
|
---
|
|
apiVersion: v1
|
|
kind: Secret
|
|
metadata:
|
|
name: mongo-auth
|
|
namespace: {{ .Release.Namespace }}
|
|
|
|
type: Opaque
|
|
stringData:
|
|
MONGO_INITDB_ROOT_USERNAME: {{ .Values.mongo_auth.username | quote }}
|
|
MONGO_INITDB_ROOT_PASSWORD: {{ .Values.mongo_auth.password | quote }}
|
|
MONGO_HOST: {{ .Values.mongo_host }}
|
|
|
|
|
|
{{- if .Values.mongo_local }}
|
|
|
|
---
|
|
kind: PersistentVolumeClaim
|
|
apiVersion: v1
|
|
metadata:
|
|
name: mongo-storage-pvc
|
|
annotations:
|
|
"helm.sh/resource-policy": keep
|
|
spec:
|
|
accessModes:
|
|
- ReadWriteOnce
|
|
|
|
resources:
|
|
requests:
|
|
storage: 2Gi
|
|
|
|
{{- if .Values.volume_storage_class }}
|
|
storageClassName: {{ .Values.volume_storage_class }}
|
|
{{- end }}
|
|
|
|
|
|
{{- if not .Values.volume_storage_class }}
|
|
---
|
|
apiVersion: v1
|
|
kind: PersistentVolume
|
|
metadata:
|
|
name: "local-mongo-store-pv"
|
|
annotations:
|
|
"helm.sh/resource-policy": keep
|
|
spec:
|
|
capacity:
|
|
storage: 2Gi
|
|
|
|
accessModes:
|
|
- "ReadWriteOnce"
|
|
|
|
hostPath:
|
|
path: /tmp/btrix-mongo-data
|
|
{{- end }}
|
|
|
|
---
|
|
apiVersion: apps/v1
|
|
kind: Deployment
|
|
metadata:
|
|
name: local-mongo
|
|
namespace: {{ .Release.Namespace }}
|
|
spec:
|
|
selector:
|
|
matchLabels:
|
|
app: local-mongo
|
|
replicas: {{ .Values.api_num_replicas }}
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: local-mongo
|
|
|
|
spec:
|
|
{{- if .Values.main_node_type }}
|
|
nodeSelector:
|
|
nodeType: {{ .Values.main_node_type }}
|
|
{{- end }}
|
|
|
|
volumes:
|
|
- name: data-db
|
|
persistentVolumeClaim:
|
|
claimName: mongo-storage-pvc
|
|
|
|
containers:
|
|
- name: mongo
|
|
image: {{ .Values.mongo_image }}
|
|
|
|
{{- if .Values.mongo_run_repair }}
|
|
command: ["mongod", "--repair"]
|
|
{{- end }}
|
|
|
|
imagePullPolicy: {{ .Values.mongo_pull_policy }}
|
|
envFrom:
|
|
- secretRef:
|
|
name: mongo-auth
|
|
|
|
volumeMounts:
|
|
- name: data-db
|
|
mountPath: /data/db
|
|
subPath: mongo
|
|
|
|
resources:
|
|
limits:
|
|
cpu: {{ .Values.mongo_limits_cpu }}
|
|
memory: {{ .Values.mongo_limits_memory }}
|
|
|
|
requests:
|
|
cpu: {{ .Values.mongo_requests_cpu }}
|
|
memory: {{ .Values.mongo_requests_memory }}
|
|
|
|
readinessProbe:
|
|
exec:
|
|
command:
|
|
- mongo
|
|
- --eval
|
|
- db.adminCommand('ping')
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
|
|
metadata:
|
|
namespace: {{ .Release.Namespace }}
|
|
name: local-mongo
|
|
labels:
|
|
app: local-mongo
|
|
|
|
spec:
|
|
type: ClusterIP
|
|
selector:
|
|
app: local-mongo
|
|
|
|
ports:
|
|
- protocol: TCP
|
|
port: 27017
|
|
targetPort: 27017
|
|
name: minio
|
|
|
|
{{- end }}
|
|
|
|
|