Compare commits
4 Commits
0e29d0aaa4
...
14cd773501
| Author | SHA1 | Date | |
|---|---|---|---|
| 14cd773501 | |||
| 37b78f079e | |||
| 0d17825eab | |||
| ffeecf65f6 |
@@ -4,3 +4,4 @@ resources:
|
|||||||
- gitea.yaml
|
- gitea.yaml
|
||||||
- renovate.yaml
|
- renovate.yaml
|
||||||
- ollama.yaml
|
- ollama.yaml
|
||||||
|
- librechat.yaml
|
||||||
|
|||||||
141
apps/librechat.yaml
Normal file
141
apps/librechat.yaml
Normal file
@@ -0,0 +1,141 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: librechat
|
||||||
|
---
|
||||||
|
# Manually create database serviceaccount
|
||||||
|
# https://github.com/mongodb/helm-charts/blob/01e50752b84de90607f12b1bd8d32c2d3493f1d2/charts/community-operator/templates/database_roles.yaml
|
||||||
|
apiVersion: v1
|
||||||
|
kind: ServiceAccount
|
||||||
|
metadata:
|
||||||
|
name: mongodb-database
|
||||||
|
namespace: librechat
|
||||||
|
---
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: Role
|
||||||
|
metadata:
|
||||||
|
name: mongodb-database
|
||||||
|
namespace: librechat
|
||||||
|
rules:
|
||||||
|
- apiGroups:
|
||||||
|
- ""
|
||||||
|
resources:
|
||||||
|
- secrets
|
||||||
|
verbs:
|
||||||
|
- get
|
||||||
|
- apiGroups:
|
||||||
|
- ""
|
||||||
|
resources:
|
||||||
|
- pods
|
||||||
|
verbs:
|
||||||
|
- patch
|
||||||
|
- delete
|
||||||
|
- get
|
||||||
|
---
|
||||||
|
kind: RoleBinding
|
||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
metadata:
|
||||||
|
name: mongodb-database
|
||||||
|
namespace: librechat
|
||||||
|
subjects:
|
||||||
|
- kind: ServiceAccount
|
||||||
|
name: mongodb-database
|
||||||
|
roleRef:
|
||||||
|
kind: Role
|
||||||
|
name: mongodb-database
|
||||||
|
apiGroup: rbac.authorization.k8s.io
|
||||||
|
---
|
||||||
|
apiVersion: mongodbcommunity.mongodb.com/v1
|
||||||
|
kind: MongoDBCommunity
|
||||||
|
metadata:
|
||||||
|
name: librechat
|
||||||
|
namespace: librechat
|
||||||
|
spec:
|
||||||
|
members: 1
|
||||||
|
type: ReplicaSet
|
||||||
|
version: "6.0.5"
|
||||||
|
security:
|
||||||
|
authentication:
|
||||||
|
modes: ["SCRAM"]
|
||||||
|
users:
|
||||||
|
- name: librechat
|
||||||
|
db: LibreChat
|
||||||
|
passwordSecretRef: # a reference to the secret that will be used to generate the user's password
|
||||||
|
name: librechat-mongodb-secret
|
||||||
|
roles:
|
||||||
|
- name: clusterAdmin
|
||||||
|
db: admin
|
||||||
|
- name: userAdminAnyDatabase
|
||||||
|
db: admin
|
||||||
|
- name: readWriteAnyDatabase
|
||||||
|
db: admin
|
||||||
|
scramCredentialsSecretName: my-scram
|
||||||
|
additionalMongodConfig:
|
||||||
|
storage.wiredTiger.engineConfig.journalCompressor: zlib
|
||||||
|
statefulSet:
|
||||||
|
spec:
|
||||||
|
volumeClaimTemplates:
|
||||||
|
- metadata:
|
||||||
|
name: data-volume
|
||||||
|
spec:
|
||||||
|
accessModes: ["ReadWriteOnce"]
|
||||||
|
storageClassName: openebs-single-replica
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 10Gi
|
||||||
|
- metadata:
|
||||||
|
name: logs-volume
|
||||||
|
spec:
|
||||||
|
accessModes: ["ReadWriteOnce"]
|
||||||
|
storageClassName: openebs-single-replica
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 1Gi
|
||||||
|
---
|
||||||
|
apiVersion: source.toolkit.fluxcd.io/v1
|
||||||
|
kind: GitRepository
|
||||||
|
metadata:
|
||||||
|
name: librechat
|
||||||
|
namespace: librechat
|
||||||
|
spec:
|
||||||
|
interval: 1h
|
||||||
|
url: https://github.com/danny-avila/LibreChat.git
|
||||||
|
ref:
|
||||||
|
tag: v0.7.7
|
||||||
|
ignore: |
|
||||||
|
# exclude all
|
||||||
|
/*
|
||||||
|
# include charts
|
||||||
|
!/charts/
|
||||||
|
---
|
||||||
|
apiVersion: helm.toolkit.fluxcd.io/v2
|
||||||
|
kind: HelmRelease
|
||||||
|
metadata:
|
||||||
|
name: librechat
|
||||||
|
namespace: librechat
|
||||||
|
spec:
|
||||||
|
interval: 10m
|
||||||
|
chart:
|
||||||
|
spec:
|
||||||
|
chart: ./charts/librechat
|
||||||
|
sourceRef:
|
||||||
|
kind: GitRepository
|
||||||
|
name: librechat
|
||||||
|
namespace: librechat
|
||||||
|
interval: 10m
|
||||||
|
values:
|
||||||
|
replicaCount: 1
|
||||||
|
# image:
|
||||||
|
# tag: v0.7.7 # Not pinned in chart for some reason
|
||||||
|
config:
|
||||||
|
envSecrets:
|
||||||
|
secretRef: librechat
|
||||||
|
secretKeyRef:
|
||||||
|
- name: MONGO_URI
|
||||||
|
secretName: librechat-librechat-librechat
|
||||||
|
secretKey: connectionString.standardSrv
|
||||||
|
env:
|
||||||
|
TRUST_PROXY: 1
|
||||||
|
DOMAIN_CLIENT: https://librechat.lumpiasty.xyz
|
||||||
|
ALLOW_REGISTRATION: false
|
||||||
@@ -20,7 +20,7 @@ spec:
|
|||||||
- name: renovate
|
- name: renovate
|
||||||
# Update this to the latest available and then enable Renovate on
|
# Update this to the latest available and then enable Renovate on
|
||||||
# the manifest
|
# the manifest
|
||||||
image: renovate/renovate:39.227.2-full
|
image: renovate/renovate:39.227.3-full
|
||||||
envFrom:
|
envFrom:
|
||||||
- secretRef:
|
- secretRef:
|
||||||
name: renovate-env
|
name: renovate-env
|
||||||
|
|||||||
33
infra/controllers/mongodb-operator.yaml
Normal file
33
infra/controllers/mongodb-operator.yaml
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
---
|
||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: mongodb
|
||||||
|
---
|
||||||
|
apiVersion: source.toolkit.fluxcd.io/v1
|
||||||
|
kind: HelmRepository
|
||||||
|
metadata:
|
||||||
|
name: mongodb
|
||||||
|
namespace: mongodb
|
||||||
|
spec:
|
||||||
|
interval: 24h
|
||||||
|
url: https://mongodb.github.io/helm-charts
|
||||||
|
---
|
||||||
|
apiVersion: helm.toolkit.fluxcd.io/v2
|
||||||
|
kind: HelmRelease
|
||||||
|
metadata:
|
||||||
|
name: mongodb-operator
|
||||||
|
namespace: mongodb
|
||||||
|
spec:
|
||||||
|
interval: 30m
|
||||||
|
chart:
|
||||||
|
spec:
|
||||||
|
chart: community-operator
|
||||||
|
version: 0.12.0
|
||||||
|
sourceRef:
|
||||||
|
kind: HelmRepository
|
||||||
|
name: mongodb
|
||||||
|
namespace: mongodb
|
||||||
|
values:
|
||||||
|
operator:
|
||||||
|
watchNamespace: "*"
|
||||||
@@ -10,6 +10,7 @@ resources:
|
|||||||
- controllers/openebs.yaml
|
- controllers/openebs.yaml
|
||||||
- controllers/k8up.yaml
|
- controllers/k8up.yaml
|
||||||
- controllers/openbao.yaml
|
- controllers/openbao.yaml
|
||||||
|
- controllers/mongodb-operator.yaml
|
||||||
- diskpools/anapistula-delrosalae-hdd.yaml
|
- diskpools/anapistula-delrosalae-hdd.yaml
|
||||||
- configs/bgp-cluster-config.yaml
|
- configs/bgp-cluster-config.yaml
|
||||||
- configs/loadbalancer-ippool.yaml
|
- configs/loadbalancer-ippool.yaml
|
||||||
|
|||||||
Reference in New Issue
Block a user