Created
May 16, 2020 03:18
-
-
Save hayleyxyz/5d1aecd7c255a597387264966e10b9e8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# mount.cifs | |
mount.cifs //hayley-pc/hayley /mnt/hayley -o credentials=/root/.cifscreds,uid=$(id -u hayley),gid=$(id -g hayley) | |
# /etc/fstab | |
echo //hayley-pc/hayley /mnt/hayley cifs credentials=/root/.cifscreds,uid=$(id -u hayley),gid=$(id -g hayley) 0 0 | |
hayley@debian:~$ cat /etc/systemd/system/mnt-hayley.mount | |
[Unit] | |
Description=cifs mount script | |
Requires=network-online.target | |
After=network-online.service | |
[Mount] | |
What=//192.168.1.100/hayley | |
Where=/mnt/hayley | |
Options=credentials=/root/.cifscreds,uid=1000,gid=1000 | |
Type=cifs | |
TimeoutIdleSec=10 | |
[Install] | |
WantedBy=multi-user.target | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment