Mendeley in a docker container!
OK, but why??? Why would you wanna run Mendeley in a docker container. Well… I don’t know about you, but for the past 2 months using Mendeley in arch-linux was a nightmare. Some comments from aur:
This package crash whenever tried to open a pdf file […]
What if I downgrade Qt, will it help?
So I decided to end this for good and run Mendely in a docker container!
Running the container
To run Mendeley in docker with GUI support, you need to have a NVIDIA graphics card and use nvidia-docker . This is currently the only caveat!
To setup NVIDIA docker v1, follow these steps.
Clone github repo
First lets’ clone our github repo that contains a collection of docker-gui-apps:
git clone email@example.com:turlucode/docker-gui-apps.git
Build the container
Go into the cloned repo and just run:
The new image is going to have the name turlucode/mendeley-nvidia .
Run the container
nvidia-docker run --rm -it --privileged --net=host --ipc=host \ -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \ -v $HOME/.Xauthority:/home/$(id -un)/.Xauthority -e XAUTHORITY=/home/$(id -un)/.Xauthority \ -v $HOME/.config:/home/$(id -un)/.config \ -v $HOME/.local/share/data:/home/$(id -un)/.local/share/data \ turlucode/mendeley-nvidia
To make you data persistent you need to mount
- .config your typical folder where usually apps save their config – located at your home folder
- local/share/data again a folder in your home, where apps store app-data
You can add those in your docker run command as illustrated in the example above.
Your are done! Enjoy!