From aaee77f81dce0e2dbea5355afee8bfae603677c7 Mon Sep 17 00:00:00 2001 From: Jonas Kaninda Date: Wed, 30 Oct 2024 04:55:17 +0100 Subject: [PATCH] chore: code refactoring --- goma.yml | 6 +++--- pkg/config.go | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/goma.yml b/goma.yml index 144cefb..a23a069 100644 --- a/goma.yml +++ b/goma.yml @@ -85,7 +85,7 @@ gateway: - path: /path-example # Rules defines which specific middleware applies to a route path rules: - - jwtAuth + - jwt # path to protect - path: /admin # Rules defines which specific middleware applies to a route path @@ -95,7 +95,7 @@ gateway: - path: /path-example # Rules defines which specific middleware applies to a route path rules: - - jwtAuth + - jwt - path: /history http: url: http://security-service:8080/security/authUser @@ -127,7 +127,7 @@ gateway: #Defines proxy middlewares middlewares: # Enable Basic auth authorization based - - name: local-auth-basic + - name: basic-auth # Authentication types | jwt, basic, OAuth type: basic rule: diff --git a/pkg/config.go b/pkg/config.go index 3f87994..dc83b70 100644 --- a/pkg/config.go +++ b/pkg/config.go @@ -156,11 +156,11 @@ type Gateway struct { AccessLog string `yaml:"accessLog" env:"GOMA_ACCESS_LOG, overwrite"` ErrorLog string `yaml:"errorLog" env:"GOMA_ERROR_LOG=, overwrite"` // DisableRouteHealthCheckError allows enabling and disabling backend healthcheck errors - DisableRouteHealthCheckError bool `yaml:"disableRouteHealthCheckError" default:"false"` + DisableRouteHealthCheckError bool `yaml:"disableRouteHealthCheckError"` //Disable allows enabling and disabling displaying routes on start - DisableDisplayRouteOnStart bool `yaml:"disableDisplayRouteOnStart" default:"false"` + DisableDisplayRouteOnStart bool `yaml:"disableDisplayRouteOnStart"` // DisableKeepAlive allows enabling and disabling KeepALive server - DisableKeepAlive bool `yaml:"disableKeepAlive" default:"false"` + DisableKeepAlive bool `yaml:"disableKeepAlive"` // InterceptErrors holds the status codes to intercept the error from backend InterceptErrors []int `yaml:"interceptErrors"` // Cors holds proxy global cors