Client.getPass: catch syserror inval when detecting non-tty use
[hcoop/domtool2.git] / bootstrap / domtool-init-acl
CommitLineData
0f9f712c
CE
1#!/bin/bash
2
3SHAREDROOT=`../bin/domtool-config -path shared-root`
4DOMTOOLROOT="$1"
5
6if [ -z "$SHAREDROOT" ]; then
7 echo "shared-root not set, domtool not built?"
8 exit 1
9fi
10
11if [ -z "$DOMTOOLROOT" ]; then
12 echo "Usage: $0 USER"
13 exit 1
14fi
15
16if [ -f $SHAREDROOT/acl ]; then
17 echo "acl file already exists. Refusing to overwrite"
18 exit 1
19fi
20
21cat > $SHAREDROOT/acl <<EOF
22$USER
23priv all
24
25EOF