Sign inSign up

cgvalle/freesurfer_vnc

By cgvalle

•Updated almost 2 years ago

Freesurfer container on a browser grafical interface.

Image
1

100K+

cgvalle/freesurfer_vnc repository overview

A docker container of the popular package FreeSurfer⁠, compatible with Windows, Mac, and Linux.

⁠Usage

Docker cli

docker run -d\
    --name freesurfer_vnc \
    -e VNC_PASSWORD=mypassword \
    -e SUBJECTS_DIR=/root/persistent/subjects \  
    -v $HOME/docker/freesurfer_VNC:/root/persistent \  # Recomended
    -p 6080:80 -p 5900:5900 \
    cgvalle/freesurfer_vnc:latest

⁠Parameters

Container images are configured using parameters passed at runtime (such as those above). These parameters are separated by a colon and indicate : respectively. For example, -p 6080:80 would expose port 80 from inside the container to be accessible from the host's IP on port 6080 outside the container.

ParameterFunction
-e VNC_PASSWORD=password for VNC login. Default is no password
-e SUBJECTS_DIRPath to freesurfer subject directory. Default is /root/persistent/subjects
-p 6080:80Access to desktop with no VNC (Browser). The container will be visible on http://127.0.0.1:6080
-p 5900:5900Access through VNC remote connection. If not in use, this option can be omited
-v /root/persistentRecommended to have a persistent volume of subjects folder.

NOTE: The folder subjects needs to be created manually during the first run if a volume is mounted in /root/persistent.

⁠Windows Setup

Windows requires Windows Subsystem for Linux (WSL⁠) version 2. Although you can install it yourself, it is recommended to use Docker Desktop⁠ software that handles this process entirely.

You can use windows terminal (command prompt) or Powershell to run the container with the command:

docker run -d\
    --name freesurfer_vnc \
    -e VNC_PASSWORD=mypassword \
    -e SUBJECTS_DIR=/root/persistent/subjects \  
    -v //c/Users/<user_name>/Documents:/root/persistent \ 
    -p 6080:80 -p 5900:5900 \
    cgvalle/freesurfer_vnc:latest

The only difference to the Mac/Linux command is the structure of the path for the persistent volume. Windows requires a double slash (/) to indicate the directory. Additionally, <user_name> should be replaced accordingly.

If everything works fine, you should be able to access it using your browser at http://127.0.0.1:6080.

⁠Freesurfer Licence

Freesurfer requires a free license that can be requested at their website⁠. You will receive a text file that needs to be placed in the /home/ubuntu/freesurfer folder (default path for $FREESURFER_HOME).

For suggestions and bug fixes, you can contact me at [email protected]⁠.

The image is based on the VNC desktop container of Vincent Emonet ⁠.

Buy Me A Coffee

Tag summary

Content type

Image

Digest

sha256:2bdc1e1af…

Size

10.1 GB

Last updated

about 4 years ago

docker pull cgvalle/freesurfer_vnc