34 lines
890 B
YAML
34 lines
890 B
YAML
|
|
##############################################################################
|
||
|
|
# Basic Auth Middleware for VictoriaMetrics Traefik IngressRoute
|
||
|
|
# CHANGE THE PASSWORD BEFORE PRODUCTION USE!
|
||
|
|
#
|
||
|
|
# To generate a new htpasswd entry:
|
||
|
|
# htpasswd -nb <username> <password>
|
||
|
|
# Then base64 encode it:
|
||
|
|
# echo -n '<htpasswd-output>' | base64
|
||
|
|
# Update the secret below with the new value.
|
||
|
|
##############################################################################
|
||
|
|
|
||
|
|
---
|
||
|
|
apiVersion: v1
|
||
|
|
kind: Secret
|
||
|
|
metadata:
|
||
|
|
name: basic-auth-secret
|
||
|
|
namespace: victoriametrics
|
||
|
|
type: Opaque
|
||
|
|
# Generate with: htpasswd -nb vultr_vm <password> | base64
|
||
|
|
# See .env for credentials
|
||
|
|
stringData:
|
||
|
|
users: |-
|
||
|
|
vultr_vm:$apr1$ZtK5B1K4$SCWPgREqKwfcrCr4FA6En1
|
||
|
|
|
||
|
|
---
|
||
|
|
apiVersion: traefik.io/v1alpha1
|
||
|
|
kind: Middleware
|
||
|
|
metadata:
|
||
|
|
name: basic-auth
|
||
|
|
namespace: victoriametrics
|
||
|
|
spec:
|
||
|
|
basicAuth:
|
||
|
|
secret: basic-auth-secret
|