mirror of
https://github.com/morten-olsen/homelab-operator.git
synced 2026-02-08 01:36:28 +01:00
Compare commits
1 Commits
8f5e148bb2
...
v0.1.14
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
32576ad37d |
16
.github/workflows/main.yml
vendored
16
.github/workflows/main.yml
vendored
@@ -71,23 +71,9 @@ jobs:
|
|||||||
environment: release
|
environment: release
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- id: create-release
|
- uses: release-drafter/release-drafter@v6
|
||||||
uses: release-drafter/release-drafter@v6
|
|
||||||
with:
|
with:
|
||||||
config-name: release-drafter-config.yml
|
config-name: release-drafter-config.yml
|
||||||
publish: true
|
publish: true
|
||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Upload Release Asset
|
|
||||||
id: upload-release-asset
|
|
||||||
uses: actions/upload-release-asset@v1
|
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
|
||||||
upload_url: ${{ steps.create-release.outputs.upload_url }}
|
|
||||||
asset_path: ./operator.yaml
|
|
||||||
asset_name: operator.yaml
|
|
||||||
asset_content_type: application/yaml
|
|
||||||
4
.gitignore
vendored
4
.gitignore
vendored
@@ -33,6 +33,4 @@ report.[0-9]_.[0-9]_.[0-9]_.[0-9]_.json
|
|||||||
# Finder (MacOS) folder config
|
# Finder (MacOS) folder config
|
||||||
.DS_Store
|
.DS_Store
|
||||||
|
|
||||||
/data/
|
/data/
|
||||||
|
|
||||||
/cloudflare.yaml
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
3.13
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
FROM node:23-slim
|
FROM node:23-alpine
|
||||||
RUN corepack enable
|
RUN corepack enable
|
||||||
COPY package.json pnpm-lock.yaml ./
|
COPY package.json pnpm-lock.yaml ./
|
||||||
RUN pnpm install --frozen-lockfile --prod
|
RUN pnpm install --frozen-lockfile --prod
|
||||||
COPY . .
|
COPY . .
|
||||||
CMD ["node", "src/index.ts"]
|
CMD ["node", "src/index.ts"]
|
||||||
13
Makefile
13
Makefile
@@ -1,14 +1,15 @@
|
|||||||
.PHONY: dev-recreate dev-destroy server-install
|
.PHONY: setup dev-recreate dev-create dev-destroy
|
||||||
|
|
||||||
|
setup:
|
||||||
|
./scripts/setup-server.sh
|
||||||
|
|
||||||
dev-destroy:
|
dev-destroy:
|
||||||
colima delete -f
|
colima delete -f
|
||||||
|
|
||||||
dev-recreate: dev-destroy
|
dev-create:
|
||||||
colima start --network-address --kubernetes -m 8 --k3s-arg="--disable helm-controller,local-storage,traefik --docker" # --mount ${PWD}/data:/data:w
|
colima start --network-address --kubernetes -m 8 --mount ${PWD}/data:/data:w --k3s-arg="--disable=helm-controller,local-storage"
|
||||||
flux install --components="source-controller,helm-controller"
|
|
||||||
|
|
||||||
setup-flux:
|
dev-recreate: dev-destroy dev-create setup
|
||||||
flux install --components="source-controller,helm-controller"
|
|
||||||
|
|
||||||
server-install:
|
server-install:
|
||||||
curl -sfL https://get.k3s.io | sh -s - --disable traefik,local-storage,helm-controller
|
curl -sfL https://get.k3s.io | sh -s - --disable traefik,local-storage,helm-controller
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
## Bootstrap repo
|
||||||
|
|
||||||
|
```
|
||||||
|
brew install fluxcd/tap/flux
|
||||||
|
make setup-server
|
||||||
|
```
|
||||||
|
|||||||
1
TODO.md
Normal file
1
TODO.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
- Fix issue with incompatible spec breaking the server
|
||||||
19
cert-issuer.yaml
Normal file
19
cert-issuer.yaml
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
apiVersion: cert-manager.io/v1
|
||||||
|
kind: ClusterIssuer
|
||||||
|
metadata:
|
||||||
|
name: letsencrypt-prod
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-options: SkipDryRunOnMissingResource=true
|
||||||
|
spec:
|
||||||
|
acme:
|
||||||
|
server: https://acme-v02.api.letsencrypt.org/directory
|
||||||
|
email: alice@alice.com
|
||||||
|
privateKeySecretRef:
|
||||||
|
name: letsencrypt-prod-account-key
|
||||||
|
solvers:
|
||||||
|
- dns01:
|
||||||
|
cloudflare:
|
||||||
|
email: alice@alice.com
|
||||||
|
apiTokenSecretRef:
|
||||||
|
name: cloudflare-api-token
|
||||||
|
key: api-token
|
||||||
14
chart/templates/clusterrole.yaml
Normal file
14
chart/templates/clusterrole.yaml
Normal file
@@ -0,0 +1,14 @@
|
|||||||
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
|
kind: ClusterRole
|
||||||
|
metadata:
|
||||||
|
name: {{ include "homelab-operator.fullname" . }}
|
||||||
|
rules:
|
||||||
|
- apiGroups: [""]
|
||||||
|
resources: ["secrets"]
|
||||||
|
verbs: ["create", "get", "watch", "list"]
|
||||||
|
- apiGroups: ["*"]
|
||||||
|
resources: ["*"]
|
||||||
|
verbs: ["get", "watch", "list", "patch"]
|
||||||
|
- apiGroups: ["apiextensions.k8s.io"]
|
||||||
|
resources: ["customresourcedefinitions"]
|
||||||
|
verbs: ["get", "create", "replace"]
|
||||||
108
chart/templates/deployment.yaml
Normal file
108
chart/templates/deployment.yaml
Normal file
@@ -0,0 +1,108 @@
|
|||||||
|
apiVersion: apps/v1
|
||||||
|
kind: Deployment
|
||||||
|
metadata:
|
||||||
|
name: {{ include "homelab-operator.fullname" . }}
|
||||||
|
labels:
|
||||||
|
{{- include "homelab-operator.labels" . | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
{{- include "homelab-operator.selectorLabels" . | nindent 6 }}
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
{{- with .Values.podAnnotations }}
|
||||||
|
annotations:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
labels:
|
||||||
|
{{- include "homelab-operator.selectorLabels" . | nindent 8 }}
|
||||||
|
spec:
|
||||||
|
{{- with .Values.imagePullSecrets }}
|
||||||
|
imagePullSecrets:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
serviceAccountName: {{ include "homelab-operator.serviceAccountName" . }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.podSecurityContext | nindent 8 }}
|
||||||
|
containers:
|
||||||
|
- name: {{ .Chart.Name }}
|
||||||
|
securityContext:
|
||||||
|
{{- toYaml .Values.securityContext | nindent 12 }}
|
||||||
|
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
|
||||||
|
imagePullPolicy: {{ .Values.image.pullPolicy }}
|
||||||
|
env:
|
||||||
|
# PostgreSQL Host
|
||||||
|
- name: POSTGRES_HOST
|
||||||
|
{{- if .Values.config.postgres.host.fromSecret.enabled }}
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: {{ .Values.config.postgres.host.fromSecret.secretName }}
|
||||||
|
key: {{ .Values.config.postgres.host.fromSecret.key }}
|
||||||
|
{{- else }}
|
||||||
|
value: {{ .Values.config.postgres.host.value | quote }}
|
||||||
|
{{- end }}
|
||||||
|
# PostgreSQL Port
|
||||||
|
- name: POSTGRES_PORT
|
||||||
|
{{- if .Values.config.postgres.port.fromSecret.enabled }}
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: {{ .Values.config.postgres.port.fromSecret.secretName }}
|
||||||
|
key: {{ .Values.config.postgres.port.fromSecret.key }}
|
||||||
|
{{- else }}
|
||||||
|
value: {{ .Values.config.postgres.port.value | quote }}
|
||||||
|
{{- end }}
|
||||||
|
# PostgreSQL User
|
||||||
|
- name: POSTGRES_USER
|
||||||
|
{{- if .Values.config.postgres.user.fromSecret.enabled }}
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: {{ .Values.config.postgres.user.fromSecret.secretName }}
|
||||||
|
key: {{ .Values.config.postgres.user.fromSecret.key }}
|
||||||
|
{{- else }}
|
||||||
|
value: {{ .Values.config.postgres.user.value | quote }}
|
||||||
|
{{- end }}
|
||||||
|
# PostgreSQL Password
|
||||||
|
- name: POSTGRES_PASSWORD
|
||||||
|
{{- if .Values.config.postgres.password.fromSecret.enabled }}
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: {{ .Values.config.postgres.password.fromSecret.secretName }}
|
||||||
|
key: {{ .Values.config.postgres.password.fromSecret.key }}
|
||||||
|
{{- else }}
|
||||||
|
value: {{ .Values.config.postgres.password.value | quote }}
|
||||||
|
{{- end }}
|
||||||
|
# Certificate Manager
|
||||||
|
- name: CERT_MANAGER
|
||||||
|
{{- if .Values.config.certManager.fromSecret.enabled }}
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: {{ .Values.config.certManager.fromSecret.secretName }}
|
||||||
|
key: {{ .Values.config.certManager.fromSecret.key }}
|
||||||
|
{{- else }}
|
||||||
|
value: {{ .Values.config.certManager.value | quote }}
|
||||||
|
{{- end }}
|
||||||
|
# Istio Gateway
|
||||||
|
- name: ISTIO_GATEWAY
|
||||||
|
{{- if .Values.config.istioGateway.fromSecret.enabled }}
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: {{ .Values.config.istioGateway.fromSecret.secretName }}
|
||||||
|
key: {{ .Values.config.istioGateway.fromSecret.key }}
|
||||||
|
{{- else }}
|
||||||
|
value: {{ .Values.config.istioGateway.value | quote }}
|
||||||
|
{{- end }}
|
||||||
|
resources:
|
||||||
|
{{- toYaml .Values.resources | nindent 12 }}
|
||||||
|
{{- with .Values.nodeSelector }}
|
||||||
|
nodeSelector:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- with .Values.affinity }}
|
||||||
|
affinity:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- with .Values.tolerations }}
|
||||||
|
tolerations:
|
||||||
|
{{- toYaml . | nindent 8 }}
|
||||||
|
{{- end }}
|
||||||
@@ -4,19 +4,13 @@
|
|||||||
|
|
||||||
image:
|
image:
|
||||||
repository: ghcr.io/morten-olsen/homelab-operator
|
repository: ghcr.io/morten-olsen/homelab-operator
|
||||||
pullPolicy: IfNotPresent
|
pullPolicy: Always
|
||||||
# Overrides the image tag whose default is the chart appVersion.
|
# Overrides the image tag whose default is the chart appVersion.
|
||||||
tag: main
|
tag: main
|
||||||
|
|
||||||
imagePullSecrets: []
|
imagePullSecrets: []
|
||||||
nameOverride: ''
|
nameOverride: ""
|
||||||
fullnameOverride: ''
|
fullnameOverride: ""
|
||||||
|
|
||||||
storage:
|
|
||||||
path: /data/volumes
|
|
||||||
reclaimPolicy: Retain
|
|
||||||
allowVolumeExpansion: false
|
|
||||||
volumeBindingMode: WaitForFirstConsumer
|
|
||||||
|
|
||||||
serviceAccount:
|
serviceAccount:
|
||||||
# Specifies whether a service account should be created
|
# Specifies whether a service account should be created
|
||||||
@@ -25,7 +19,7 @@ serviceAccount:
|
|||||||
annotations: {}
|
annotations: {}
|
||||||
# The name of the service account to use.
|
# The name of the service account to use.
|
||||||
# If not set and create is true, a name is generated using the fullname template
|
# If not set and create is true, a name is generated using the fullname template
|
||||||
name: ''
|
name: ""
|
||||||
|
|
||||||
podAnnotations: {}
|
podAnnotations: {}
|
||||||
|
|
||||||
@@ -57,3 +51,53 @@ nodeSelector: {}
|
|||||||
tolerations: []
|
tolerations: []
|
||||||
|
|
||||||
affinity: {}
|
affinity: {}
|
||||||
|
|
||||||
|
# Configuration for the homelab operator
|
||||||
|
config:
|
||||||
|
# PostgreSQL database configuration
|
||||||
|
postgres:
|
||||||
|
host:
|
||||||
|
# Direct value (used when fromSecret.enabled is false)
|
||||||
|
value: "127.0.0.1"
|
||||||
|
# Secret reference (used when fromSecret.enabled is true)
|
||||||
|
fromSecret:
|
||||||
|
enabled: false
|
||||||
|
secretName: ""
|
||||||
|
key: "POSTGRES_HOST"
|
||||||
|
|
||||||
|
port:
|
||||||
|
value: "5432"
|
||||||
|
fromSecret:
|
||||||
|
enabled: false
|
||||||
|
secretName: ""
|
||||||
|
key: "POSTGRES_PORT"
|
||||||
|
|
||||||
|
user:
|
||||||
|
value: "postgres"
|
||||||
|
fromSecret:
|
||||||
|
enabled: false
|
||||||
|
secretName: ""
|
||||||
|
key: "POSTGRES_USER"
|
||||||
|
|
||||||
|
password:
|
||||||
|
value: ""
|
||||||
|
fromSecret:
|
||||||
|
enabled: true # Default to secret for sensitive data
|
||||||
|
secretName: "postgres-secret"
|
||||||
|
key: "POSTGRES_PASSWORD"
|
||||||
|
|
||||||
|
# Certificate manager configuration
|
||||||
|
certManager:
|
||||||
|
value: "letsencrypt-prod"
|
||||||
|
fromSecret:
|
||||||
|
enabled: false
|
||||||
|
secretName: ""
|
||||||
|
key: "CERT_MANAGER"
|
||||||
|
|
||||||
|
# Istio gateway configuration
|
||||||
|
istioGateway:
|
||||||
|
value: "istio-ingress"
|
||||||
|
fromSecret:
|
||||||
|
enabled: false
|
||||||
|
secretName: ""
|
||||||
|
key: "ISTIO_GATEWAY"
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: audiobookshelf
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: OidcClient
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
redirectUris:
|
|
||||||
- path: /audiobookshelf/auth/openid/callback
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
matchingMode: strict
|
|
||||||
- path: /audiobookshelf/auth/openid/mobile-redirect
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
matchingMode: strict
|
|
||||||
@@ -1,52 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
strategy:
|
|
||||||
type: Recreate
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: '{{ .Values.image.repository }}:{{ .Values.image.tag }}'
|
|
||||||
imagePullPolicy: '{{ .Values.image.pullPolicy }}'
|
|
||||||
ports:
|
|
||||||
- name: http
|
|
||||||
containerPort: 80
|
|
||||||
protocol: TCP
|
|
||||||
livenessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
readinessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /config
|
|
||||||
name: config
|
|
||||||
- mountPath: /metadata
|
|
||||||
name: metadata
|
|
||||||
- mountPath: /audiobooks
|
|
||||||
name: audiobooks
|
|
||||||
- mountPath: /podcasts
|
|
||||||
name: podcasts
|
|
||||||
volumes:
|
|
||||||
- name: config
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-config'
|
|
||||||
- name: metadata
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-metadata'
|
|
||||||
- name: audiobooks
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: books
|
|
||||||
- name: podcasts
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: podcasts
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,24 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-config'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
|
|
||||||
---
|
|
||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-metadata'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 80
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
image:
|
|
||||||
repository: ghcr.io/advplyr/audiobookshelf
|
|
||||||
tag: 2.26.1
|
|
||||||
pullPolicy: IfNotPresent
|
|
||||||
subdomain: audiobookshelf
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: ByteStash
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-headless'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
clusterIP: None
|
|
||||||
ports:
|
|
||||||
- port: 5000
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: HttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: OidcClient
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
redirectUris:
|
|
||||||
- path: /api/auth/oidc/callback
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
matchingMode: strict
|
|
||||||
@@ -1,55 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
serviceName: '{{ .Release.Name }}-headless'
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: ghcr.io/jordan-dalby/bytestash:latest
|
|
||||||
ports:
|
|
||||||
- containerPort: 5000
|
|
||||||
name: http
|
|
||||||
env:
|
|
||||||
- name: ALLOW_NEW_ACCOUNTS
|
|
||||||
value: 'true'
|
|
||||||
- name: DISABLE_INTERNAL_ACCOUNTS
|
|
||||||
value: 'true'
|
|
||||||
- name: OIDC_ENABLED
|
|
||||||
value: 'true'
|
|
||||||
- name: OIDC_DISPLAY_NAME
|
|
||||||
value: OIDC
|
|
||||||
- name: OIDC_CLIENT_ID
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: clientId
|
|
||||||
- name: OIDC_CLIENT_SECRET
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: clientSecret
|
|
||||||
- name: OIDC_ISSUER_URL
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: configuration
|
|
||||||
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /data/snippets
|
|
||||||
name: data
|
|
||||||
volumes:
|
|
||||||
- name: data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-data'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-data'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 5000
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
subdomain: bytestash
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: gitea
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: OidcClient
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
redirectUris:
|
|
||||||
- path: /user/oauth2/Authentik/callback
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
matchingMode: strict
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: PostgresDatabase
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,96 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
strategy:
|
|
||||||
type: Recreate
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: '{{ .Values.image.repository }}:{{ .Values.image.tag }}'
|
|
||||||
imagePullPolicy: '{{ .Values.image.pullPolicy }}'
|
|
||||||
ports:
|
|
||||||
- name: http
|
|
||||||
containerPort: 3000
|
|
||||||
protocol: TCP
|
|
||||||
livenessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
readinessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /data
|
|
||||||
name: data
|
|
||||||
env:
|
|
||||||
- name: TZ
|
|
||||||
value: '{{ .Values.globals.timezone }}'
|
|
||||||
- name: USER_UID
|
|
||||||
value: '1000'
|
|
||||||
- name: USER_GID
|
|
||||||
value: '1000'
|
|
||||||
- name: GITEA__service__REQUIRE_EXTERNAL_REGISTRATION_PASSWORD
|
|
||||||
value: 'true'
|
|
||||||
- name: GITEA__service__ENABLE_BASIC_AUTHENTICATION
|
|
||||||
value: 'true'
|
|
||||||
- name: GITEA__service__ENABLE_PASSWORD_SIGNIN_FORM
|
|
||||||
value: 'false'
|
|
||||||
- name: GITEA__service__DEFAULT_KEEP_EMAIL_PRIVATE
|
|
||||||
value: 'true'
|
|
||||||
- name: GITEA__service__DEFAULT_USER_IS_RESTRICTED
|
|
||||||
value: 'true'
|
|
||||||
- name: GITEA__service__DEFAULT_USER_VISIBILITY
|
|
||||||
value: 'private'
|
|
||||||
- name: GITEA__service__DEFAULT_ORG_VISIBILITY
|
|
||||||
value: 'private'
|
|
||||||
- name: GITEA__service__ALLOW_ONLY_EXTERNAL_REGISTRATION
|
|
||||||
value: 'true'
|
|
||||||
- name: GITEA__other__SHOW_FOOTER_POWERED_BY
|
|
||||||
value: 'false'
|
|
||||||
- name: GITEA__other__SHOW_FOOTER_TEMPLATE_LOAD_TIME
|
|
||||||
value: 'false'
|
|
||||||
- name: GITEA__other__SHOW_FOOTER_VERSION
|
|
||||||
value: 'false'
|
|
||||||
- name: GITEA__repository__ENABLE_PUSH_CREATE_USER
|
|
||||||
value: 'true'
|
|
||||||
- name: GITEA__repository__ENABLE_PUSH_CREATE_ORG
|
|
||||||
value: 'true'
|
|
||||||
- name: GITEA__openid__ENABLE_OPENID_SIGNIN
|
|
||||||
value: 'false'
|
|
||||||
- name: GITEA__openid__ENABLE_OPENID_SIGNUP
|
|
||||||
value: 'false'
|
|
||||||
- name: GITEA__database__DB_TYPE
|
|
||||||
value: postgres
|
|
||||||
- name: GITEA__database__NAME
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: database
|
|
||||||
- name: GITEA__database__HOST
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: host
|
|
||||||
- name: GITEA__database__USER
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: user
|
|
||||||
- name: GITEA__database__PASSWD
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: password
|
|
||||||
volumes:
|
|
||||||
- name: data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-data'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-data'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 3000
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
timezone: Europe/Amsterdam
|
|
||||||
image:
|
|
||||||
repository: docker.gitea.com/gitea
|
|
||||||
tag: latest
|
|
||||||
pullPolicy: IfNotPresent
|
|
||||||
subdomain: gitea
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: headscale
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: OidcClient
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
redirectUris:
|
|
||||||
- path: /oidc/callback
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
matchingMode: strict
|
|
||||||
@@ -1,70 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: ConfigMap
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-config-template'
|
|
||||||
data:
|
|
||||||
config.yaml.template: |
|
|
||||||
server_url: ${PUBLIC_URL}
|
|
||||||
listen_addr: 0.0.0.0:8080
|
|
||||||
metrics_listen_addr: 0.0.0.0:9090
|
|
||||||
grpc_listen_addr: 0.0.0.0:50443
|
|
||||||
|
|
||||||
private_key_path: /var/lib/headscale/private_key # Path inside the container
|
|
||||||
|
|
||||||
noise:
|
|
||||||
private_key_path: /var/lib/headscale/noise_private_key # Path inside the container
|
|
||||||
|
|
||||||
listen_routes: false
|
|
||||||
base_domain: "${PUBLIC_URL}" # For client routes and DNS push.
|
|
||||||
|
|
||||||
derp:
|
|
||||||
server:
|
|
||||||
enabled: false
|
|
||||||
region_id: 999
|
|
||||||
region_code: "headscale"
|
|
||||||
region_name: "Headscale Embedded DERP"
|
|
||||||
stun_listen_addr: "0.0.0.0:3478"
|
|
||||||
automatically_add_embedded_derp_region: true
|
|
||||||
urls:
|
|
||||||
- https://controlplane.tailscale.com/derpmap/default
|
|
||||||
auto_update_enabled: true
|
|
||||||
update_frequency: 24h
|
|
||||||
|
|
||||||
oidc:
|
|
||||||
enabled: true
|
|
||||||
only_start_if_oidc_is_available: true
|
|
||||||
issuer: "${OIDC_ISSUER_URL}"
|
|
||||||
client_id: "${OIDC_CLIENT_ID}"
|
|
||||||
client_secret: "${OIDC_CLIENT_SECRET}"
|
|
||||||
scopes: ["openid", "profile", "email"]
|
|
||||||
redirect_url: "${PUBLIC_URL}/oidc/callback"
|
|
||||||
pkce:
|
|
||||||
enabled: true
|
|
||||||
method: S256
|
|
||||||
|
|
||||||
|
|
||||||
# DNS configuration
|
|
||||||
dns:
|
|
||||||
magic_dns: false
|
|
||||||
override_local_dns: true # Push Headscale's DNS settings to clients
|
|
||||||
ttl: 60
|
|
||||||
nameservers:
|
|
||||||
global:
|
|
||||||
- 1.1.1.1 # Cloudflare DNS
|
|
||||||
#- 10.43.0.10 # Replace with your ClusterIP for kube-dns/CoreDNS
|
|
||||||
# Domains to search for (e.g., for Kubernetes services)
|
|
||||||
search_domains:
|
|
||||||
- svc.cluster.local
|
|
||||||
- cluster.local
|
|
||||||
|
|
||||||
auto_create_users: true
|
|
||||||
|
|
||||||
oidc_user_property: preferred_username # Or 'email' or 'sub'
|
|
||||||
|
|
||||||
prefixes:
|
|
||||||
v4: 10.20.20.0/24 # Example: A /24 subnet for your VPN clients
|
|
||||||
|
|
||||||
database:
|
|
||||||
type: sqlite
|
|
||||||
sqlite:
|
|
||||||
path: /var/lib/headscale/db.sqlite
|
|
||||||
@@ -1,97 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
# To expose WireGuard UDP directly, we need a NodePort service.
|
|
||||||
# The Pod needs to be aware of the external port it's being exposed on.
|
|
||||||
# The easiest way to get WireGuard to listen on the correct port and make it
|
|
||||||
# externally accessible is to use `hostNetwork: true` for the UDP component,
|
|
||||||
# or by directly specifying the listen port in Headscale config if the NodePort is stable.
|
|
||||||
|
|
||||||
# OPTION 1: Best for simple homelab on bare metal where host network traffic isn't an issue
|
|
||||||
# hostNetwork: true # This makes the pod listen directly on the node's IPs
|
|
||||||
# dnsPolicy: ClusterFirstWithHostNet # Required if using hostNetwork
|
|
||||||
|
|
||||||
initContainers:
|
|
||||||
- name: generate-config
|
|
||||||
image: alpine/git # A small image with 'envsubst' available or easily installable
|
|
||||||
imagePullPolicy: IfNotPresent
|
|
||||||
command: ['sh', '-c']
|
|
||||||
args:
|
|
||||||
- |
|
|
||||||
# Install envsubst if it's not present (alpine/git may not have it by default)
|
|
||||||
apk update && apk add bash gettext
|
|
||||||
|
|
||||||
# Substitute environment variables into the template
|
|
||||||
# The vars are passed via `env` section below
|
|
||||||
envsubst < /config-template/config.yaml.template > /etc/headscale/config.yaml
|
|
||||||
|
|
||||||
mkdir -p /etc/headscale
|
|
||||||
# Optional: Verify the generated config
|
|
||||||
echo "--- Generated Headscale Configuration ---"
|
|
||||||
cat /etc/headscale/config.yaml
|
|
||||||
echo "---------------------------------------"
|
|
||||||
env:
|
|
||||||
# These are the variables that `envsubst` will look for and replace
|
|
||||||
- name: PUBLIC_URL
|
|
||||||
value: 'https://{{ .Values.subdomain }}.olsen.cloud'
|
|
||||||
- name: OIDC_ISSUER_URL
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: configurationIssuer
|
|
||||||
- name: OIDC_CLIENT_ID
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: clientId
|
|
||||||
- name: OIDC_CLIENT_SECRET
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: clientSecret
|
|
||||||
# Add any other variables used in config.yaml.template here
|
|
||||||
volumeMounts:
|
|
||||||
- name: config-template
|
|
||||||
mountPath: /config-template # Mount the ConfigMap as a volume
|
|
||||||
readOnly: true
|
|
||||||
- name: headscale-config
|
|
||||||
mountPath: /etc/headscale # Destination for the generated config
|
|
||||||
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: headscale/headscale:latest # Use the official image
|
|
||||||
command: ['headscale', 'serve']
|
|
||||||
ports:
|
|
||||||
- name: http-api
|
|
||||||
containerPort: 8080
|
|
||||||
protocol: TCP
|
|
||||||
- name: wireguard-udp
|
|
||||||
containerPort: 41641
|
|
||||||
protocol: UDP
|
|
||||||
volumeMounts:
|
|
||||||
- name: headscale-data
|
|
||||||
mountPath: /var/lib/headscale
|
|
||||||
- name: headscale-config
|
|
||||||
mountPath: /etc/headscale
|
|
||||||
volumes:
|
|
||||||
- name: config-template
|
|
||||||
configMap:
|
|
||||||
name: '{{ .Release.Name }}-config-template'
|
|
||||||
- name: headscale-config
|
|
||||||
emptyDir: {}
|
|
||||||
- name: headscale-data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-data'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-data'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 8080
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
- name: wireguard-udp # TODO: should this be a LB service?
|
|
||||||
port: 41641
|
|
||||||
targetPort: 41641
|
|
||||||
protocol: UDP
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
image:
|
|
||||||
repository: headscale/headscale
|
|
||||||
tag: latest
|
|
||||||
pullPolicy: IfNotPresent
|
|
||||||
subdomain: headscale
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: Jellyfin
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
https://www.authelia.com/integration/openid-connect/clients/jellyfin/
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: OidcClient
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.environment }}'
|
|
||||||
redirectUris:
|
|
||||||
- path: /sso/OID/redirect/Authentik
|
|
||||||
subdomain: '{{ .Values.globals.subdomain }}'
|
|
||||||
matchingMode: strict
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-config'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.environment }}'
|
|
||||||
@@ -1,52 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
strategy:
|
|
||||||
type: Recreate
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: '{{ .Values.image.repository }}:{{ .Values.image.tag }}'
|
|
||||||
imagePullPolicy: '{{ .Values.image.pullPolicy }}'
|
|
||||||
ports:
|
|
||||||
- name: http
|
|
||||||
containerPort: 8096
|
|
||||||
protocol: TCP
|
|
||||||
livenessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
readinessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /config
|
|
||||||
name: config
|
|
||||||
- mountPath: /media/movies
|
|
||||||
name: movies
|
|
||||||
- mountPath: /media/tv-shows
|
|
||||||
name: tvshows
|
|
||||||
- mountPath: /media/music
|
|
||||||
name: music
|
|
||||||
volumes:
|
|
||||||
- name: config
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-config'
|
|
||||||
- name: movies
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: movies
|
|
||||||
- name: tvshows
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: tvshows
|
|
||||||
- name: music
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: music
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 8096
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
image:
|
|
||||||
repository: docker.io/jellyfin/jellyfin
|
|
||||||
tag: latest
|
|
||||||
pullPolicy: IfNotPresent
|
|
||||||
subdomain: jellyfin
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: metamcp
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: PostgresDatabase
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,79 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
strategy:
|
|
||||||
type: Recreate
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: '{{ .Values.image.repository }}:{{ .Values.image.tag }}'
|
|
||||||
imagePullPolicy: '{{ .Values.image.pullPolicy }}'
|
|
||||||
ports:
|
|
||||||
- name: http
|
|
||||||
containerPort: 12008
|
|
||||||
protocol: TCP
|
|
||||||
livenessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
readinessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /data
|
|
||||||
name: data
|
|
||||||
env:
|
|
||||||
- name: TZ
|
|
||||||
value: '{{ .Values.globals.timezone }}'
|
|
||||||
- name: APP_URL
|
|
||||||
value: https://metamcp.olsen.cloud # TODO: Change
|
|
||||||
- name: NEXT_PUBLIC_APP_URL
|
|
||||||
value: https://metamcp.olsen.cloud # TODO: Change
|
|
||||||
- name: BETTER_AUTH_SECRET
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-secrets'
|
|
||||||
key: betterauth
|
|
||||||
- name: DATABASE_URL
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: url
|
|
||||||
- name: POSTGRES_DB
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: database
|
|
||||||
- name: POSTGRES_HOST
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: host
|
|
||||||
- name: POSTGRES_PORT
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: port
|
|
||||||
- name: POSTGRES_USER
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: user
|
|
||||||
- name: POSTGRES_PASSWORD
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: password
|
|
||||||
volumes:
|
|
||||||
- name: data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-data'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-data'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,9 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: GenerateSecret
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-secrets'
|
|
||||||
spec:
|
|
||||||
fields:
|
|
||||||
- name: betterauth
|
|
||||||
encoding: base64
|
|
||||||
length: 64
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 12008
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
timezone: Europe/Amsterdam
|
|
||||||
image:
|
|
||||||
repository: ghcr.io/metatool-ai/metamcp
|
|
||||||
tag: latest
|
|
||||||
pullPolicy: IfNotPresent
|
|
||||||
subdomain: metamcp
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: ByteStash
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: OidcClient
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
redirectUris:
|
|
||||||
- path: /api/auth/oidc/callback
|
|
||||||
subdomain: bytestash
|
|
||||||
matchingMode: strict
|
|
||||||
@@ -1,55 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
serviceName: '{{ .Release.Name }}-headless'
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: ghcr.io/miniflux/miniflux:latest
|
|
||||||
ports:
|
|
||||||
- containerPort: 8080
|
|
||||||
name: http
|
|
||||||
env:
|
|
||||||
- name: ALLOW_NEW_ACCOUNTS
|
|
||||||
value: 'true'
|
|
||||||
- name: DISABLE_INTERNAL_ACCOUNTS
|
|
||||||
value: 'true'
|
|
||||||
- name: OIDC_ENABLED
|
|
||||||
value: 'true'
|
|
||||||
- name: OIDC_DISPLAY_NAME
|
|
||||||
value: OIDC
|
|
||||||
- name: OIDC_CLIENT_ID
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: clientId
|
|
||||||
- name: OIDC_CLIENT_SECRET
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: clientSecret
|
|
||||||
- name: OIDC_ISSUER_URL
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: configuration
|
|
||||||
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /data/snippets
|
|
||||||
name: data
|
|
||||||
volumes:
|
|
||||||
- name: data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-data'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-data'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 8080
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
subdomain: miniflux
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: Jellyfin
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: PostgresDatabase
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,73 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
strategy:
|
|
||||||
type: Recreate
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: '{{ .Values.image.repository }}:{{ .Values.image.tag }}'
|
|
||||||
imagePullPolicy: '{{ .Values.image.pullPolicy }}'
|
|
||||||
ports:
|
|
||||||
- name: http
|
|
||||||
containerPort: 5678
|
|
||||||
protocol: TCP
|
|
||||||
livenessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
readinessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /home/node/.n8n
|
|
||||||
name: data
|
|
||||||
env:
|
|
||||||
- name: TZ
|
|
||||||
value: '{{ .Values.globals.timezone }}'
|
|
||||||
- name: GENERIC_TIMEZONE
|
|
||||||
value: '{{ .Values.globals.timezone }}'
|
|
||||||
- name: N8N_ENFORCE_SETTINGS_FILE_PERMISSIONS
|
|
||||||
value: 'true'
|
|
||||||
- name: N8N_RUNNERS_ENABLED
|
|
||||||
value: 'true'
|
|
||||||
- name: DB_TYPE
|
|
||||||
value: postgresdb
|
|
||||||
- name: DB_POSTGRESDB_DATABASE
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: database
|
|
||||||
- name: DB_POSTGRESDB_HOST
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: host
|
|
||||||
- name: DB_POSTGRESDB_PORT
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: port
|
|
||||||
- name: DB_POSTGRESDB_USER
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: user
|
|
||||||
- name: DB_POSTGRESDB_PASSWORD
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-pg-connection'
|
|
||||||
key: password
|
|
||||||
volumes:
|
|
||||||
- name: data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-data'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-data'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 5678
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
timezone: Europe/Amsterdam
|
|
||||||
image:
|
|
||||||
repository: docker.n8n.io/n8nio/n8n
|
|
||||||
tag: latest
|
|
||||||
pullPolicy: IfNotPresent
|
|
||||||
subdomain: n8n
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: ollama
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: OidcClient
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
redirectUris:
|
|
||||||
- path: /oauth/oidc/callback
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
matchingMode: strict
|
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
strategy:
|
|
||||||
type: Recreate
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: '{{ .Values.image.repository }}:{{ .Values.image.tag }}'
|
|
||||||
imagePullPolicy: '{{ .Values.image.pullPolicy }}'
|
|
||||||
ports:
|
|
||||||
- name: http
|
|
||||||
containerPort: 11434
|
|
||||||
protocol: TCP
|
|
||||||
livenessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
readinessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /root/.ollama
|
|
||||||
name: data
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
- name: data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-data'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-data'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 11434
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
image:
|
|
||||||
repository: ollama/ollama
|
|
||||||
tag: 0.11.8
|
|
||||||
pullPolicy: IfNotPresent
|
|
||||||
subdomain: openwebui
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: openwebui
|
|
||||||
@@ -1,10 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: OidcClient
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
redirectUris:
|
|
||||||
- path: /oauth/oidc/callback
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
matchingMode: strict
|
|
||||||
@@ -1,70 +0,0 @@
|
|||||||
apiVersion: apps/v1
|
|
||||||
kind: Deployment
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
strategy:
|
|
||||||
type: Recreate
|
|
||||||
replicas: 1
|
|
||||||
selector:
|
|
||||||
matchLabels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
containers:
|
|
||||||
- name: '{{ .Release.Name }}'
|
|
||||||
image: '{{ .Values.image.repository }}:{{ .Values.image.tag }}'
|
|
||||||
imagePullPolicy: '{{ .Values.image.pullPolicy }}'
|
|
||||||
ports:
|
|
||||||
- name: http
|
|
||||||
containerPort: 8080
|
|
||||||
protocol: TCP
|
|
||||||
livenessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
readinessProbe:
|
|
||||||
tcpSocket:
|
|
||||||
port: http
|
|
||||||
volumeMounts:
|
|
||||||
- mountPath: /app/backend/data
|
|
||||||
name: data
|
|
||||||
env:
|
|
||||||
- name: ENABLE_SIGNUP
|
|
||||||
value: 'false'
|
|
||||||
- name: WEBUI_URL # TODO: remove
|
|
||||||
value: https://openwebui.olsen.cloud
|
|
||||||
- name: ENABLE_OAUTH_PERSISTENT_CONFIG
|
|
||||||
value: 'false'
|
|
||||||
- name: ENABLE_OAUTH_SIGNUP
|
|
||||||
value: 'true'
|
|
||||||
- name: OAUTH_MERGE_ACCOUNTS_BY_EMAIL
|
|
||||||
value: 'true'
|
|
||||||
- name: OAUTH_PROVIDER_NAME
|
|
||||||
value: authentik
|
|
||||||
- name: OPENID_PROVIDER_URL
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: configuration
|
|
||||||
- name: OAUTH_CLIENT_ID
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: clientId
|
|
||||||
- name: OAUTH_CLIENT_SECRET
|
|
||||||
valueFrom:
|
|
||||||
secretKeyRef:
|
|
||||||
name: '{{ .Release.Name }}-client'
|
|
||||||
key: clientSecret
|
|
||||||
- name: ENABLE_LOGIN_FORM
|
|
||||||
value: 'false'
|
|
||||||
- name: OPENID_REDIRECT
|
|
||||||
value: https://openwebui.olsen.cloud/oauth/oidc/callback
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
- name: data
|
|
||||||
persistentVolumeClaim:
|
|
||||||
claimName: '{{ .Release.Name }}-data'
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
apiVersion: homelab.mortenolsen.pro/v1
|
|
||||||
kind: ExternalHttpService
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
environment: '{{ .Values.globals.environment }}'
|
|
||||||
subdomain: '{{ .Values.subdomain }}'
|
|
||||||
destination:
|
|
||||||
host: '{{ .Release.Name }}.{{ .Release.Namespace }}.svc.cluster.local'
|
|
||||||
port:
|
|
||||||
number: 80
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
kind: PersistentVolumeClaim
|
|
||||||
apiVersion: v1
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}-data'
|
|
||||||
spec:
|
|
||||||
accessModes:
|
|
||||||
- 'ReadWriteOnce'
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: '1Gi'
|
|
||||||
storageClassName: '{{ .Values.globals.environment }}'
|
|
||||||
@@ -1,15 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: Service
|
|
||||||
metadata:
|
|
||||||
name: '{{ .Release.Name }}'
|
|
||||||
labels:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
spec:
|
|
||||||
type: ClusterIP
|
|
||||||
ports:
|
|
||||||
- port: 80
|
|
||||||
targetPort: 8080
|
|
||||||
protocol: TCP
|
|
||||||
name: http
|
|
||||||
selector:
|
|
||||||
app: '{{ .Release.Name }}'
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
globals:
|
|
||||||
environment: prod
|
|
||||||
image:
|
|
||||||
repository: ghcr.io/open-webui/open-webui
|
|
||||||
tag: main
|
|
||||||
pullPolicy: IfNotPresent
|
|
||||||
subdomain: openwebui
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: Resources
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolume
|
|
||||||
metadata:
|
|
||||||
name: books
|
|
||||||
labels:
|
|
||||||
type: nfs
|
|
||||||
spec:
|
|
||||||
capacity:
|
|
||||||
storage: 10Gi
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
persistentVolumeReclaimPolicy: Retain
|
|
||||||
storageClassName: manual-books
|
|
||||||
nfs:
|
|
||||||
path: '{{ .Values.books.path }}'
|
|
||||||
server: '{{ .Values.host }}'
|
|
||||||
---
|
|
||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolumeClaim
|
|
||||||
metadata:
|
|
||||||
name: books
|
|
||||||
spec:
|
|
||||||
storageClassName: manual-books
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 10Gi
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolume
|
|
||||||
metadata:
|
|
||||||
name: movies
|
|
||||||
labels:
|
|
||||||
type: nfs
|
|
||||||
spec:
|
|
||||||
capacity:
|
|
||||||
storage: 10Gi
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
persistentVolumeReclaimPolicy: Retain
|
|
||||||
storageClassName: manual-movies
|
|
||||||
nfs:
|
|
||||||
path: '{{ .Values.movies.path }}'
|
|
||||||
server: '{{ .Values.host }}'
|
|
||||||
---
|
|
||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolumeClaim
|
|
||||||
metadata:
|
|
||||||
name: movies
|
|
||||||
spec:
|
|
||||||
storageClassName: manual-movies
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 10Gi
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolume
|
|
||||||
metadata:
|
|
||||||
name: music
|
|
||||||
labels:
|
|
||||||
type: nfs
|
|
||||||
spec:
|
|
||||||
capacity:
|
|
||||||
storage: 10Gi
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
persistentVolumeReclaimPolicy: Retain
|
|
||||||
storageClassName: manual-music
|
|
||||||
nfs:
|
|
||||||
path: '{{ .Values.music.path }}'
|
|
||||||
server: '{{ .Values.host }}'
|
|
||||||
---
|
|
||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolumeClaim
|
|
||||||
metadata:
|
|
||||||
name: music
|
|
||||||
spec:
|
|
||||||
storageClassName: manual-music
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 10Gi
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolume
|
|
||||||
metadata:
|
|
||||||
name: podcasts
|
|
||||||
labels:
|
|
||||||
type: nfs
|
|
||||||
spec:
|
|
||||||
capacity:
|
|
||||||
storage: 10Gi
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
persistentVolumeReclaimPolicy: Retain
|
|
||||||
storageClassName: manual-podcasts
|
|
||||||
nfs:
|
|
||||||
path: '{{ .Values.podcasts.path }}'
|
|
||||||
server: '{{ .Values.host }}'
|
|
||||||
---
|
|
||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolumeClaim
|
|
||||||
metadata:
|
|
||||||
name: podcasts
|
|
||||||
spec:
|
|
||||||
storageClassName: manual-podcasts
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 10Gi
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolume
|
|
||||||
metadata:
|
|
||||||
name: tvshows
|
|
||||||
labels:
|
|
||||||
type: nfs
|
|
||||||
spec:
|
|
||||||
capacity:
|
|
||||||
storage: 10Gi
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
persistentVolumeReclaimPolicy: Retain
|
|
||||||
storageClassName: manual-tvshows
|
|
||||||
nfs:
|
|
||||||
path: '{{ .Values.tvshows.path }}'
|
|
||||||
server: '{{ .Values.host }}'
|
|
||||||
---
|
|
||||||
apiVersion: v1
|
|
||||||
kind: PersistentVolumeClaim
|
|
||||||
metadata:
|
|
||||||
name: tvshows
|
|
||||||
spec:
|
|
||||||
storageClassName: manual-tvshows
|
|
||||||
accessModes:
|
|
||||||
- ReadWriteMany
|
|
||||||
resources:
|
|
||||||
requests:
|
|
||||||
storage: 10Gi
|
|
||||||
@@ -1,11 +0,0 @@
|
|||||||
host: 192.168.20.106
|
|
||||||
movies:
|
|
||||||
path: /mnt/HDD/Movies
|
|
||||||
tvshows:
|
|
||||||
path: /mnt/HDD/TV-Shows
|
|
||||||
music:
|
|
||||||
path: /mnt/HDD/Music2
|
|
||||||
books:
|
|
||||||
path: /mnt/HDD/Books
|
|
||||||
podcasts:
|
|
||||||
path: /mnt/HDD/Podcasts
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
apiVersion: v2
|
|
||||||
version: 1.0.0
|
|
||||||
name: root
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
apiVersion: argoproj.io/v1alpha1
|
|
||||||
kind: ApplicationSet
|
|
||||||
metadata:
|
|
||||||
name: homelab-apps
|
|
||||||
namespace: '{{ .Values.env }}-argo'
|
|
||||||
spec:
|
|
||||||
generators:
|
|
||||||
- git:
|
|
||||||
repoURL: '{{ .Values.repo }}'
|
|
||||||
revision: '{{ .Values.ref }}'
|
|
||||||
directories:
|
|
||||||
- path: charts/apps/*
|
|
||||||
include: '.*'
|
|
||||||
exclude: '.*.disabled'
|
|
||||||
template:
|
|
||||||
metadata:
|
|
||||||
name: '{{`{{path.basename}}`}}'
|
|
||||||
spec:
|
|
||||||
project: default
|
|
||||||
source:
|
|
||||||
repoURL: '{{ .Values.repo }}'
|
|
||||||
targetRevision: '{{ .Values.ref }}'
|
|
||||||
path: charts/apps/{{`{{path.basename}}`}}
|
|
||||||
helm:
|
|
||||||
values: |
|
|
||||||
globals: {{ .Values.globals | toYaml | nindent 14 }}
|
|
||||||
destination:
|
|
||||||
server: https://kubernetes.default.svc
|
|
||||||
namespace: '{{ .Values.globals.env }}'
|
|
||||||
syncPolicy:
|
|
||||||
automated:
|
|
||||||
prune: true
|
|
||||||
selfHeal: true
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user