diff --git a/README.md b/README.md index 581e3f0..8d71a6b 100644 --- a/README.md +++ b/README.md @@ -23,17 +23,19 @@ Simple, easy to use, and configure. - [Docker Hub](https://hub.docker.com/r/jkaninda/goma-gateway) - [Github](https://github.com/jkaninda/goma-gateway) +## Documentation is found at + ### Feature - [x] Reverse proxy - [x] API Gateway - [x] Domain/host based request routing - [x] Multi domain request routing -- [x] Cors +- [x] Cross-Origin Resource Sharing (CORS) - [ ] Support TLS - [x] Backend errors interceptor - [x] Authentication middleware - - [x] JWT `HTTP Bearer Token` + - [x] JWT ` client authorization based on the result of a request` - [x] Basic-Auth - [ ] OAuth - [x] Implement rate limiting @@ -124,7 +126,7 @@ gateway: path: /public ## Rewrite a request path # e.g rewrite: /store to / - rewrite: /healthz + rewrite: / destination: https://example.com #DisableHeaderXForward Disable X-forwarded header. # [X-Forwarded-Host, X-Forwarded-For, Host, Scheme ] @@ -155,8 +157,8 @@ gateway: - name: Authentication service path: /auth rewrite: / - destination: 'http://security-service:8080' - healthCheck: /internal/health/ready + destination: https://example.com + healthCheck: / cors: {} middlewares: - api-forbidden-paths @@ -208,17 +210,17 @@ middlewares: # # Add header to the next request from AuthRequest header, depending on your requirements # Key is AuthRequest's response header Key, and value is Request's header Key - # In case you want to get headers from the Authentication service and inject them into the next request's headers + # In case you want to get headers from the authentication service and inject them into the next request headers. headers: userId: X-Auth-UserId userCountryId: X-Auth-UserCountryId - # In case you want to get headers from the Authentication service and inject them to the next request's params + # In case you want to get headers from the Authentication service and inject them to the next request params. params: userCountryId: countryId - # The server will return 404 + # The server will return 403 - name: api-forbidden-paths type: access - ## Forbidden paths + ## prevents access paths paths: - /swagger-ui/* - /v2/swagger-ui/* diff --git a/docs/_config.yml b/docs/_config.yml index 69dfe16..e57c3cb 100644 --- a/docs/_config.yml +++ b/docs/_config.yml @@ -17,9 +17,9 @@ title: Goma Gateway email: hi@jonaskaninda.com description: >- # this means to ignore newlines until "baseurl:" Goma Gateway is a lightweight API Gateway and Reverse Proxy. - -baseurl: "/" # the subpath of your site, e.g. /blog -url: "jkaninda.github.io/goma-gateway" # the base hostname & protocol for your site, e.g. http://example.com + +baseurl: "" # the subpath of your site, e.g. /blog +url: "jkaninda.github.io/goma-gateway/" # the base hostname & protocol for your site, e.g. http://example.com twitter_username: jonaskaninda github_username: jkaninda diff --git a/goma.yml b/goma.yml index 8496ac3..35fe24c 100644 --- a/goma.yml +++ b/goma.yml @@ -45,7 +45,7 @@ gateway: path: /public ## Rewrite a request path # e.g rewrite: /store to / - rewrite: /healthz + rewrite: / destination: https://example.com #DisableHeaderXForward Disable X-forwarded header. # [X-Forwarded-Host, X-Forwarded-For, Host, Scheme ] @@ -76,8 +76,8 @@ gateway: - name: Authentication service path: /auth rewrite: / - destination: 'http://security-service:8080' - healthCheck: /internal/health/ready + destination: https://example.com + healthCheck: / cors: {} middlewares: - api-forbidden-paths @@ -129,17 +129,17 @@ middlewares: # # Add header to the next request from AuthRequest header, depending on your requirements # Key is AuthRequest's response header Key, and value is Request's header Key - # In case you want to get headers from the Authentication service and inject them into the next request's headers + # In case you want to get headers from the authentication service and inject them into the next request headers. headers: userId: X-Auth-UserId userCountryId: X-Auth-UserCountryId - # In case you want to get headers from the Authentication service and inject them to the next request's params + # In case you want to get headers from the Authentication service and inject them to the next request params. params: userCountryId: countryId -# The server will return 404 +# The server will return 403 - name: api-forbidden-paths type: access - ## Forbidden paths + ## prevents access paths paths: - /swagger-ui/* - /v2/swagger-ui/*