lens-metric-proxy

by owanio1992

Helm chartv0.1.0App stable

this chart help create a proxy for [lens](https://k8slens.dev) query external metric data source it's helpful when you have self-managed prometeus lens config PROMETHEUS: Helm PROMETHEUS SERVICE ADDRESS: lens-metric/lens-metric-proxy:80

About this chart

lens-metric-proxy

this chart help create a proxy for lens query external metric data source it's helpful when you have self-managed prometeus
lens config
PROMETHEUS: Helm
PROMETHEUS SERVICE ADDRESS: lens-metric/lens-metric-proxy:80

Values

KeyTypeDefaultDescription
affinityobject{}Affinity for pod assignment
config.nginx_confstring"user nginx;\nworker_processes auto;\n\nerror_log /var/log/nginx/error.log notice;\npid /var/run/nginx.pid;\n\n\nevents {\n worker_connections 1024;\n}\n\n\nhttp {\n include /etc/nginx/mime.types;\n default_type application/octet-stream;\n\n log_format main '$remote_addr - $remote_user [$time_local] \"$request\" '\n '$status $body_bytes_sent \"$http_referer\" '\n '\"$http_user_agent\" \"$http_x_forwarded_for\" \"$request_body\"';\n\n access_log /var/log/nginx/access.log main;\n\n sendfile on;\n #tcp_nopush on;\n\n keepalive_timeout 65;\n\n #gzip on;\n\n include /etc/nginx/conf.d/*.conf;\n}\n"Main nginx configuration
config.prometheus_conf_templatestring"server {\n listen 80 default_server;\n\n proxy_connect_timeout 300;\n proxy_send_timeout 300;\n proxy_read_timeout 300;\n send_timeout 300;\n resolver 1.1.1.1;\n location /health {\n return 200;\n }\n location / {\n proxy_pass http://$PROMETHEUS_HOST/prometheus$request_uri;\n # proxy_set_header X-Scope-OrgID \"$MIMIR_TENANT\";\n }\n\n}\n"Prometheus proxy configuration template for nginx
env[0]object{"name":"PROMETHEUS_HOST","value":""}The host of the prometheus backend
fullnameOverridestring""Override the full name
image.pullPolicystring"IfNotPresent"Image pull policy
image.repositorystring"nginx"Image repository
image.tagstring""Overrides the image tag whose default is the chart appVersion.
imagePullSecretslist[]Image pull secrets
livenessProbeobject{"httpGet":{"path":"/health","port":"http"}}Liveness probe configuration
nameOverridestring""Override the chart name
nodeSelectorobject{}Node selector for pod assignment
podAnnotationsobject{}Annotations for the pod
podLabelsobject{}Labels for the pod
podSecurityContextobject{}Pod security context e.g. fsGroup: 2000
readinessProbeobject{"httpGet":{"path":"/health","port":"http"}}Readiness probe configuration
replicaCountint1Number of replicas
resourcesobject{}Resource requests and limits e.g. limits: cpu: 100m memory: 128Mi requests: cpu: 100m memory: 128Mi
securityContextobject{}Container security context e.g. capabilities: drop: - ALL readOnlyRootFilesystem: true runAsNonRoot: true runAsUser: 1000
service.portint80Service port
service.typestring"ClusterIP"Service type
serviceAccount.annotationsobject{}Annotations to add to the service account
serviceAccount.automountbooltrueAutomatically mount a ServiceAccount's API credentials?
serviceAccount.createboolfalseSpecifies whether a service account should be created
serviceAccount.namestring""The name of the service account to use. If not set and create is true, a name is generated using the fullname template
tolerationslist[]Tolerations for pod assignment
volumeMountslist[{"mountPath":"/etc/nginx/nginx.conf","name":"config","subPath":"nginx.conf"},{"mountPath":"/etc/nginx/templates/prometheus.conf.template","name":"config","subPath":"prometheus.conf.template"}]Volume mounts for the container
volumeslist[{"configMap":{"name":"{{ include \"lens-metric-proxy.fullname\" . }}"},"name":"config"}]Volumes to mount

Autogenerated from chart metadata using helm-docs v1.14.2

Deploy lens-metric-proxy with OpenTenant

Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has lens-metric-proxy on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.

  1. Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
  2. Place the chartlens-metric-proxy is pinned at v0.1.0 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
  3. ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below
opentenant validate opentenant.yaml
terraform init && terraform apply