mirror of
https://github.com/lordmathis/dev-cluster.git
synced 2025-12-23 17:14:25 +00:00
47 lines
1.2 KiB
YAML
47 lines
1.2 KiB
YAML
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: llamactl-proxy
|
|
namespace: homelab-proxy
|
|
annotations:
|
|
tailscale.com/tailnet-fqdn: ${LLAMACTL_TAILNET_FQDN}
|
|
spec:
|
|
type: ExternalName
|
|
externalName: placeholder
|
|
ports:
|
|
- port: ${LLAMACTL_INTERNAL_PORT}
|
|
name: http
|
|
|
|
---
|
|
apiVersion: traefik.io/v1alpha1
|
|
kind: IngressRoute
|
|
metadata:
|
|
name: llamactl-ingress
|
|
namespace: homelab-proxy
|
|
spec:
|
|
entryPoints:
|
|
- websecure
|
|
routes:
|
|
# Protected route for internal management API
|
|
- match: Host(`${LLAMACTL_DOMAIN}`) && PathPrefix(`/api/v1`)
|
|
kind: Rule
|
|
services:
|
|
- name: llamactl-proxy
|
|
port: ${LLAMACTL_INTERNAL_PORT}
|
|
middlewares:
|
|
- name: "auth-authelia@kubernetescrd"
|
|
# Unprotected route for OpenAI compatible API (uses API keys)
|
|
- match: Host(`${LLAMACTL_DOMAIN}`) && PathPrefix(`/v1`)
|
|
kind: Rule
|
|
services:
|
|
- name: llamactl-proxy
|
|
port: ${LLAMACTL_INTERNAL_PORT}
|
|
# Catch-all route
|
|
- match: Host(`${LLAMACTL_DOMAIN}`)
|
|
kind: Rule
|
|
services:
|
|
- name: llamactl-proxy
|
|
port: ${LLAMACTL_INTERNAL_PORT}
|
|
middlewares:
|
|
- name: "auth-authelia@kubernetescrd"
|