This repository has been archived on 2023-05-02. You can view files and clone it, but you cannot make any changes to it's state, such as pushing and creating new issues, pull requests or comments.
neo/tools/mount.sh
2022-12-14 09:17:51 +01:00

17 lines
277 B
Bash

#!/bin/sh
ORIGIN=`pwd`
if [ "$(id -u)" -ne 0 ]; then
echo "Please run as root"
exit
fi
cd /etc/credentials
for file in ./*; do
echo "# mounting $file"
. $file
mount -t cifs //$domain/backup /mnt/$file -o credentials=/etc/credentials/$file
fi
cd $ORIGIN