maxhoesel.smb_mount

maxhoesel.smb_mount

A role to set up a systemd mount unit for accessing an SMB share.

NOTE: If you want to use the utf8 character set (which is the default for this role) on minimal Ubuntu server installations, you need to install an additional kernel image package and reboot the host. This role will handle those steps automatically.

Requirements

  • Must have become permissions
  • A host running a recent version of Ubuntu

Role Variables

smb_mount_reboot_for_kernel
  • Indicates whether to automatically reboot the host to complete the installation of the necessary kernel modules for UTF-8 SMB support.
  • Default: yes
smb_mount_src
  • URL of the SMB share to mount. It should be in a format that mount understands, like //server.com/mount_path.
  • Required: yes
smb_mount_dest
  • The path where the share will be mounted. It must be an absolute path.
  • Must NOT contain a dash in the file path. For more information, see the systemd mount docs.
  • Required: yes
smb_mount_guest
  • Indicates whether to mount the share in guest mode.
  • Default: no
smb_mount_username
  • The username used to log in to the remote server. This is required if smb_mount_guest is set to no.
smb_mount_password
  • The password for logging into the remote server. This is required if smb_mount_guest is set to no.
smb_mount_uid
  • Sets the owner of the mounted files to this local UID.
  • Equivalent to uid= in fstab mount options.
  • Default: {{ ansible_user_uid }}
smb_mount_gid
  • Sets the owner group of the mounted files to this local GID.
  • Equivalent to gid= in fstab mount options.
  • Default: {{ ansible_user_gid }}
smb_mount_filemode
  • Sets the permission mode for all files in the share.
  • Default: 0755
smb_mount_dirmode
  • Sets the permission mode for all directories in the share.
  • Default: 0755
smb_mount_options
  • Additional options to specify when mounting the share.
  • Default: ""

License

GPL 3 or later

Informazioni sul progetto

Create a Systemd Mount unit for a SMB share

Installa
ansible-galaxy install maxhoesel.smb_mount
Licenza
Unknown
Download
3.6k
Proprietario
Junior Automation and Infrastructure Engineer, Bachelor in CompSci. I write Ansible content and DevOps-related tools, mostly in Rust