Skip to content

Spring Cloud Gateway to manage authentication/authorization and intelligent routing to ppddm-manager, service discovery, GUI portal and portal-backend

License

Apache-2.0, Unknown licenses found

Licenses found

Apache-2.0
LICENSE
Unknown
LICENSE-AGREEMENT.md
Notifications You must be signed in to change notification settings

fair4health/gateway

FAIR4Health Gateway

Build Status codecov.io Quality Gate Docker Build Docker Pulls License

Description

FAIR4Health Gateway to provide authentication, authorization and intelligent routing. It provides the following routing:

  • [POST] /oauth/login
  • [GET] /oauth/user

Technology

  • Java 8+
  • Maven for Java dependency management
  • Spring Boot
  • Spring Cloud Gateway
  • Lombok for the models

Functionalities

  • OAuth 2.0 Authentication and Authorization
  • Intelligent routing

How to deploy

Compile and package the project with

mvn clean package

and execute

java -jar target/gateway.war

It can also be run as:

mvn spring-boot:run

Deploy the Keycloak auth repo. Execute the following curl:

curl -X POST "http://localhost:8083/oauth/login" -H "accept: */*" -H "Content-Type: application/json" -d "{ \"password\": \"string\", \"username\": \"string\"}"

It should redirect the post to http://localhost:8081/login and provide the following response:

{
  "timestamp" : "2020-07-19T18:06:19.810+0000",
  "status" : 401,
  "error" : "Unauthorized",
  "message" : "Unauthorised access to protected resource",
  "path" : "/login"
}

Environment variables

OAUTH_EASY_URL=
LOGGING_FOLDER=
LOGGING_MODE=

Docker deployment

Build the image:

docker build -t fair4health/gateway .

Simple deployment:

docker run --name gateway -d fair4health/gateway

Logging can be also configured using LOGGING_FOLDER and sharing a volume (this is useful for example for ELK processing). The level of the logging can be configured with LOGGING_MODE (dev|prod):

docker run --name gateway -d -v /tmp/log/gateway:/log/calculator -e LOGGING_FOLDER=/log/test -e LOGGING_MODE=dev fair4health/gateway

License

Apache 2.0

By downloading this software, the downloader agrees with the specified terms and conditions of the License Agreement and the particularities of the license provided.

About

Spring Cloud Gateway to manage authentication/authorization and intelligent routing to ppddm-manager, service discovery, GUI portal and portal-backend

Topics

Resources

License

Apache-2.0, Unknown licenses found

Licenses found

Apache-2.0
LICENSE
Unknown
LICENSE-AGREEMENT.md

Code of conduct

Stars

Watchers

Forks

Packages

No packages published