blob: 59eb1b2c7ac06188a6a5a1bb993b9f9b4236febc (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
#!/bin/bash
if [ "$#" -lt 3 ]; then
echo "Incorrect args. invoke gluster-swift-add-user $GLUSTER_USER $GLUSTER_PASSWORD $GLUSTER_VOLUMES"
exit 1
else
GLUSTER_USER=$1
GLUSTER_PASSWORD=$2
GLUSTER_VOLUMES=$(echo $3 | cut -d" " -f1)
sleep 5
gswauth-prep -A http://0.0.0.0:8080/auth -K gswauthkey
gswauth-add-account -K gswauthkey $GLUSTER_VOLUMES
gswauth-add-user -K gswauthkey -a $GLUSTER_VOLUMES $GLUSTER_USER $GLUSTER_PASSWORD
fi
|