Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
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