A demo project consisting of 4 services managing users and cards.
- Clone. Be sure Git is installed.
git clone https://github.com/NadChel/em-services- Navigate to the project root.
cd em-services- Run
docker-compose.yml. Docker Engine should be running (on Windows, you can open Docker Desktop).
docker-compose up- Once the services are up, open their UI pages and visit the endpoints. By default, UI is exposed at
localhost:<port>/swagger-ui.html.
| Service | Description | Default port | GH | DH |
|---|---|---|---|---|
| migration-service | Initializes the DB on start-up and exits. | N/A | link | link |
| token-service | Performs user login, issuing signed JWTs. | 8080 | link | link |
| user-service | Manages users: selects, saves, deletes. | 8090 | link | link |
| card-service | Manages cards: selects, saves, status updates. Also, deposits and transfers. | 8100 | link | link |
| db | PostgreSQL database. | 5432 | N/A | link |
- All business endpoints, except
/login, require authentication. Once you've successfully logged in via thetoken-serviceand got a JWT string, click theAuthorizebutton in a service's UI and paste it in theValuefield. */admin/**endpoints require ADMIN privileges.- The root admin, if absent, is created automatically on
user-servicestart-up (admin:admin by default). It's the only user that exists in the database on the first run. - If you want to run it in your IDE (not with
docker-compose), be sure to include an.envfile in thecard-serviceroot. The file must specifyAPP_ENCRYPTION_PASSWORDandAPP_ENCRYPTION_SALT(hexadecimal strings)..envis purposefully excluded from Git.