summaryrefslogtreecommitdiffstats
path: root/gluster-s3object/CentOS/docker-gluster-s3/update_gluster_vol.sh
blob: dfb891d4f8a0d79fb280089a3250680506788d90 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/bash

# To update gluster volume name in swift-volumes, used by swift-gen-builders.service
if [ -z "$GLUSTER_VOLUMES" ]; then
        echo "You need to set GLUSTER_VOLUMES env variable"
        exit 1
else
        echo "GLUSTER_VOLUMES env variable is set. Update in swift-volumes"
        sed -i.bak '/^GLUSTER_VOLUMES=/s/=.*/='\""$GLUSTER_VOLUMES"\"'/' /etc/sysconfig/swift-volumes
fi

# Hand off to CMD
exec "$@"