Skip to content
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: 5 additions & 3 deletions .github/workflows/go-integrations.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ jobs:
version:
- '1.22'
- '1.23'
- '1.24'
- '1.25'
platform:
- ubuntu-latest
fail-fast: false
Expand Down Expand Up @@ -161,14 +163,14 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: dashboard_linux_arm64
path: dist/dashboard_linux_arm64/
path: dist/dashboard_linux_arm64_v8.0/
if-no-files-found: error

- name: Upload darwin_arm64
uses: actions/upload-artifact@v4
with:
name: dashboard_darwin_arm64
path: dist/dashboard_darwin_arm64/
path: dist/dashboard_darwin_arm64_v8.0/
if-no-files-found: error

- name: Upload windows_amd64_v3
Expand All @@ -182,7 +184,7 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: dashboard_windows_arm64
path: dist/dashboard_windows_arm64/
path: dist/dashboard_windows_arm64_v8.0/
if-no-files-found: error

- name: Upload Metadata
Expand Down
6 changes: 4 additions & 2 deletions .golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@ linters:
# Computes and checks the cyclomatic complexity of functions.
# (replaced by cyclop)
- gocyclo
# Check logger calls conform to a specific format (seems to have some issues
# around the use of structured logging currently)
- loggercheck
# Nlreturn checks for a new line before return and branch statements to
# increase code clarity
# (this is better managed by wsl)
Expand All @@ -80,8 +83,7 @@ linters:
- wrapcheck

## Deprecated
- execinquery
- gomnd
- tenv

run:
timeout: 1m
5 changes: 5 additions & 0 deletions charts/dashboard/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ configure it through the `values.yaml` file.
| ingress.labels | object | `{}` | Set any additional labels which should be added to the Ingress resource |
| ingress.hosts | list | `[]` | Set the hostname and path mappings for this service on the Ingress |
| ingress.tls | list | `[]` | Set the TLS secret and hostnames for this service on the Ingress |
| httpRoute.create | bool | `false` | Set whether or not to create the HTTPRoute resource for the dashboard Service using the Gateway APIs |
| httpRoute.parentRefs | list | `[]` | Set the parent references targeting the Gateways which will route traffic to this service |
| httpRoute.hostnames | list | `[]` | Set the hostnames this HTTPRoute should respond to via the Gateways |
| httpRoute.annotations | object | `{}` | Set any additional annotations which should be added to the HTTPRoute resource |
| httpRoute.labels | object | `{}` | Set any additional labels which should be added to the HTTPRoute resource |
| serviceAccount.create | bool | `false` | Set whether or not to create a ServiceAccount resource for the dashboard service |
| serviceAccount.name | string | `nil` | Override the name of the ServiceAccount @default `.Chart.Name` |
| serviceAccount.annotations | object | `{}` | Set any additional annotations which should be added to the ServiceAccount resource |
Expand Down
34 changes: 34 additions & 0 deletions charts/dashboard/templates/http-route.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
{{- if .Values.httpRoute.create -}}
apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
name: {{ include "dashboard.fullname" . }}
{{- with .Values.httpRoute.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
labels:
{{- include "dashboard.labels" . | nindent 4 }}
{{- with .Values.httpRoute.labels }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- with .Values.httpRoute.parentRefs }}
parentRefs:
{{- toYaml . | nindent 4 }}
{{- end }}
{{- with .Values.httpRoute.hostnames }}
hostnames:
{{- toYaml . | nindent 4 }}
{{- end }}
rules:
- matches:
- path:
type: PathPrefix
value: /
backendRefs:
- kind: Service
name: {{ include "dashboard.fullname" . }}-frontend
port: {{ .Values.service.webPort }}
{{- end }}
19 changes: 19 additions & 0 deletions charts/dashboard/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,25 @@ ingress:
# hosts:
# - dashboard.local

httpRoute:
# -- Set whether or not to create the HTTPRoute resource for the dashboard
# Service using the Gateway APIs
create: false
# -- Set the parent references targeting the Gateways which will route traffic
# to this service
parentRefs: []
# - group: gateway.networking.k8s.io
# kind: Gateway
# namespace: example
# name: default
# -- Set the hostnames this HTTPRoute should respond to via the Gateways
hostnames: []
# -- Set any additional annotations which should be added to the HTTPRoute
# resource
annotations: {}
# -- Set any additional labels which should be added to the HTTPRoute resource
labels: {}

serviceAccount:
# -- Set whether or not to create a ServiceAccount resource for the dashboard
# service
Expand Down
3 changes: 3 additions & 0 deletions internal/serve/metrics/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ func NewService() *Service {
func (s *Service) Start(e chan error) {
if s.server == nil {
s.health.Metrics = false
//nolint: loggercheck // The s.attr here points to an slog.Group
slog.Error(
"Failed to start metrics service",
slog.Group("error", slog.String("message", "service not configured")),
Expand All @@ -98,13 +99,15 @@ func (s *Service) Start(e chan error) {
e <- ErrServiceNotConfigured
}

//nolint: loggercheck // The s.attr here points to an slog.Group
slog.Info("Starting dashboard metrics service", s.attr)

s.health.Metrics = true

err := s.server.ListenAndServe()
if err != nil && !errors.Is(err, http.ErrServerClosed) {
s.health.Metrics = false
//nolint: loggercheck // The s.attr here points to an slog.Group
slog.Error(
"Failed to start metrics service",
slog.Group("error", slog.String("message", err.Error())),
Expand Down
Loading