Resolve "Create an user in Dockerfile"
name: Feature
about: New features or wider changes
Closes #79
Description
This MR allows to launch docker container as current user with correct right permissions on mounted volumes
For example:
$ ./docker/docker_run.sh visiomanager:MR-79 -u $(id -u) -v `pwd`/resources:/app/resources
This command allows to launch docker container as current user. This user is added in root group in docker container, so he is able to write both in /app folder and in /app/resources sqlite database
Changelog
- Added possibility to launch container as current user
How to test
- Run script docker/docker_build.sh
- Set correctly environment variables
- Run script docker/docker_run.sh with correct parameters (as described above)
- Test the application
Misc
As dockerfile is based on ubuntu 20, the pyjwt library is more recent than in ubuntu 18. This library returns a str when we call jwt.encode whereas precedent version 1.7.1 returns bytes. It is fixed by forcing version in requirements.txt.
An issue should be created to update the code according to last library version.
Edited by HUYNH Kim-Tam