$ docker-compose up
$ http://localhost:3888/api/docs/
# username
$ [email protected]
# password
$ admin
# url
$ http://localhost:5050/
# docker exec -it <container_name> sh
# user
$ admin
# password
$ secret
# DB
$ postgres
# port
$ 5432
# url
$ postgres
- dockerization with nginx for proxy
- backend part implemented with typescript
- use concurrency, race condition
- use postgreSQL and i/o data with DTOs
- use typeOrm and configs
- implement third-party service talking heads in separate module
- how implement tests - added for User Service, you can see in (user-controller.spec.ts)
- frontend part implemented with svelte and js
- for frontend part for login used store
- for getting data from third-party service for specific user using promise async await on FE
# access to urls
# api backend
$ http://localhost:3888/
# api backend swagger
$ http://localhost:3888/api/docs
# pg-admin
$ http://localhost:5050/
# svelte front-end part
$ http://localhost:3001/
Didn't implement for FE part sign-up, just login. To create user just open swagger doc and create user or use curl
# curl
curl -X 'POST' \
'http://localhost:3888/user' \
-H 'accept: application/json' \
-H 'Content-Type: application/json' \
-d '{
"email": "[email protected]",
"password": "qwerty"
}'
First run
docker-compose up
- Login
- After the logging store saved and redirect to after login section (didn't implement localStorage or sessionStorage - to keep auth data), just for SPA.
- click introduce
- see video with auth id user, firstName added like argument to backend
- additionally added endpoint for history (see swagger head endpoint), where can fetch all videos which has been played for specific user