Script para montar pastas compartilhadas

#!/bin/bash
# Script pra mounta as pastas da rede
# O arquivo cifspw deve estar assim:
############################################

Publicidade

sudo mount //fileserver/pasta1 $HOME/pasta1 -o dir_mode=0777,file_mode=0777,credentials=/etc/cifspw
sudo mount //fileserver/pasta2 $HOME/pasta2 -o dir_mode=0777,file_mode=0777,credentials=/etc/cifspw

 

Criem o arquivo “/etc/cifspw”

username=joao
password=1234