2025-03-20 14:58:01 +01:00

12 lines
278 B
Bash

#!/bin/bash
# Ip passée en paramètre
ip=$1
workdir=/root/deploy
ssh root@$ip "mkdir $workdir" 2> /dev/null
scp "./createGroups.sh" "./logins.csv" "createUsers.sh" root@$ip:$workdir
ssh root@$ip >> EOF
bash createGroups.sh
bash createUsers.sh
rm -R $workdir
EOF