Currently all the endpoints of FastAPI server are open. We should add an authentication layer which will protect these endpoints from unauthorised access.
Points to consider:
- Keep it optional. Because on local dev server it will be hassle.
- If we are using just username and password, where will it be stored securely? Adding this means the docker container will be stateful.
- Oauth2 implementation can be done.