basic-auth

This commit is contained in:
ari committed 2026-02-16 16:22:45 -05:00
1 parent 0cbc11a949
commit 0a5301aba8
6 files changed
+32 -2

No files matched your search

+6
View File
@@ -86,4 +86,10 @@ function run-template-compose-app() {
# echo $out | bat -l yaml
}
function run-htpasswd() {
: Generates htpasswd file
: dev htpasswd
openssl passwd -apr1 ${@}
}
start_cli $@
@@ -19,3 +19,4 @@ ingress:
service: smartboi
port: 8000
useSecondaryDomain: true
middleware: basic-auth-smartboi
@@ -0,0 +1,21 @@
{{ range $user, $pass := .Values.users }}
---
apiVersion: v1
kind: Secret
metadata:
name: "secret-basic-auth-{{$user}}"
type: kubernetes.io/basic-auth
stringData:
username: {{ $user }}
password: {{ $pass }}
---
apiVersion: traefik.io/v1alpha1
kind: Middleware
metadata:
name: "basic-auth-{{$user}}"
spec:
redirectScheme:
scheme: https
basicAuth:
secret: "secret-basic-auth-{{$user}}"
{{ end }}
-2
View File
@@ -1,5 +1,3 @@
reverseProxy:
home:
port: "8123"
+3
View File
@@ -15,3 +15,6 @@ services: []
tailScaleServices: []
ns:
argocd: plugin-argo-cd
users:
smartboi: "makingmoney"
+1
View File
@@ -25,6 +25,7 @@
yq
bat
jq
openssl
# k8s
kubectx
k3d