Skip to content

Instantly share code, notes, and snippets.

@zopieux
Created February 26, 2018 23:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save zopieux/146d35986896a39fcbc4e865d1460da8 to your computer and use it in GitHub Desktop.
Save zopieux/146d35986896a39fcbc4e865d1460da8 to your computer and use it in GitHub Desktop.
Docker on NFS with automount
# /etc/systemd/system/docker.service.d/override.conf
# TODO: use systemd-automount?
# defeats the purpose of the /net discovering service, though
[Service]
# trigger mount (share is /docker)
ExecStartPre=/usr/bin/stat /net/SERVER/docker
# umount
ExecStopPost=/usr/bin/umount /net/SERVER/docker
ExecStart=
ExecStart=/usr/bin/dockerd -H fd:// --data-root=/net/SERVER/docker
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment