systemctl bind
linux
Ephemerally bind-mount a file or directory from the host into a unit's mount namespace.
More info →Examples (4)
Bind-mount a host path into the same location inside the unit
systemctl bind unit /path/to/host_directoryBind-mount a host path into a different location inside the unit
systemctl bind unit /path/to/host_directory /path/to/unit_directoryBind-mount a path as read-only inside the unit
systemctl bind unit /path/to/host_directory --read-onlyCreate the destination path inside the unit before binding
systemctl bind unit /path/to/host_directory /path/to/unit_directory --mkdirmade by @shridhargupta | data from tldr-pages