Skip to content
Snippets Groups Projects
Verified Commit 21897a28 authored by David Beniamine's avatar David Beniamine
Browse files

Fix bad svc copy

parent 87b7e503
Branches
No related tags found
No related merge requests found
#!/bin/bash
src="/home/s"
dest="/home/adhomes"
cd $src
for dir in $src/*; do
base=$(basename $dir)
echo $base
if [ -L "$base" ]; then
echo "Skipping $base as it is a simlink"
continue;
fi
for sub in groupes perso .ftp; do
mv $base/$sub/* $dest/$base/$sub
mv $base/$sub/.* $dest/$base/$sub
rmdir $base/$sub
done
rmdir $base
ln -s $dest/$base
done
#!/bin/bash
setfacl -Rm user:svc-prof:rwx /home/s/svc-prof
setfacl -Rm default:user:svc-prof:rwx /home/s/svc-prof
setfacl -Rm group::--- /home/s/svc-prof
setfacl -Rm default:group::--- /home/s/svc-prof
setfacl -Rm other::--- /home/s/svc-prof
setfacl -Rm default:other::--- /home/s/svc-prof
setfacl -Rm user:svc-dir:rwx /home/s/svc-dir
setfacl -Rm default:user:svc-dir:rwx /home/s/svc-dir
setfacl -Rm group::--- /home/s/svc-dir
setfacl -Rm default:group::--- /home/s/svc-dir
setfacl -Rm other::--- /home/s/svc-dir
setfacl -Rm default:other::--- /home/s/svc-dir
setfacl -Rm user:svc-dirmat:rwx /home/s/svc-dirmat
setfacl -Rm default:user:svc-dirmat:rwx /home/s/svc-dirmat
setfacl -Rm group::--- /home/s/svc-dirmat
setfacl -Rm default:group::--- /home/s/svc-dirmat
setfacl -Rm other::--- /home/s/svc-dirmat
setfacl -Rm default:other::--- /home/s/svc-dirmat
chown -R svc-ce /home/adhomes/svc-ce
chown -R svc-cp /home/adhomes/svc-cp
chown -R svc-cm /home/adhomes/svc-cm
chown -R svc-dir /home/adhomes/svc-dir
chown -R svc-dirmat /home/adhomes/svc-dirmat
chown -R svc-prof /home/adhomes/svc-prof
chown -R svc-perisco /home/adhomes/svc-perisco
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment