Skip to content
This repository has been archived by the owner on Dec 17, 2024. It is now read-only.

[+] allow setting arbitrary configs to the webui pod #754

Merged
merged 3 commits into from
Mar 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions helm-chart/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -207,6 +207,11 @@ spec:
- name: {{ .Chart.Name }}-webui
image: "{{ .Values.webui.image.repository }}:{{ .Values.webui.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.webui.image.pullPolicy }}
{{- if .Values.webui.command }}
command: [{{- range $index, $cmd := .Values.webui.command }}
"{{ $cmd }}"{{- if lt $index (sub (len $.Values.webui.command) 1) }},{{ end }}
{{- end }}]
{{- end }}
env:
- name: PW2_PGHOST
value: {{ .Values.postgresql.host | default (printf "%s-postgresql" (include "pgwatch2.fullname" .)) }}
Expand Down Expand Up @@ -249,6 +254,9 @@ spec:
value: {{ .Values.webui.user | default "pgwatch2" }}
- name: PW2_WEBPASSWORD
value: {{ .Values.webui.password | default "pgwatch2" }}
envFrom:
- configMapRef:
name: {{ include "pgwatch2.fullname" . }}-env
{{- with .Values.daemon.resources }}
resources:
{{- toYaml . | nindent 12 }}
Expand Down
2 changes: 1 addition & 1 deletion webpy/templates/stats-summary.html
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ <h2 class="sub-header">pg_stat_statements Top 50 by {{sort_column}} {% if dbname
<tbody>
{% for d in data %}
<tr>
<td><a href="{{grafana_baseurl}}/dashboard/db/single-query-details?var-queryid={{d['queryid']}}&var-dbname={{dbname}}" target="_blank">{{d['queryid']}}</td>
<td><a href="{{grafana_baseurl}}/d/single-query-details/single-query-details?var-queryid={{d['queryid']}}&var-dbname={{dbname}}" target="_blank">{{d['queryid']}}</td>
<td>{{d['query']}}</td>
<td>{{d['total_time']}}</td>
<td>{{d['mean_time']}}</td>
Expand Down