summaryrefslogtreecommitdiff
path: root/user-init
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2002-09-02 12:24:24 +0000
committerJonas Smedegaard <dr@jones.dk>2002-09-02 12:24:24 +0000
commit3cbebd9a46e00c4efdaa26f91471d86ce2b79af0 (patch)
tree0be7428eef17a5f457925ecf4300b8a459d120f2 /user-init
parentdfb47e031d236a5a91016a127e3784f2dae813ae (diff)
user-init: Add support for webscripts and webdate dirs.
Diffstat (limited to 'user-init')
-rwxr-xr-xuser-init20
1 files changed, 19 insertions, 1 deletions
diff --git a/user-init b/user-init
index fd85be0..3e5332f 100755
--- a/user-init
+++ b/user-init
@@ -214,7 +214,7 @@ for user in $USERS; do
chown root: $dir
chmod u+rw,go+r,a+X $dir
done
- for dir in `find $HOME -mindepth 2 -maxdepth 2 -type d | egrep "^$HOME/websites/"`; do
+ for dir in `find $HOME -mindepth 2 -maxdepth 2 -type d | egrep "^$HOME/websites/"`; do
chown -R $user: $dir
# chmod -R u=rw,go=r,a+X $webdir
#TODO: Only cgi scripts (.cgi and .pl) should be executable
@@ -224,6 +224,24 @@ for user in $USERS; do
rm -rf $dir/Network\ Trash\ Folder
fi
done
+ for dir in `find $HOME -mindepth 1 -maxdepth 1 -type d | egrep "^$HOME/webscripts"`; do
+ chown root: $dir
+ chmod u+rw,go+r,a+X $dir
+ done
+ for dir in `find $HOME -mindepth 2 -maxdepth 2 -type d | egrep "^$HOME/webscripts/"`; do
+ chown -R $user: $dir
+# chmod -R u=rw,go=r,a+X $webdir
+#TODO: Only cgi scripts (.cgi and .pl) should be executable
+ chmod -R u+rw,go+r,a+X $dir
+ done
+ for dir in `find $HOME -mindepth 1 -maxdepth 1 -type d | egrep "^$HOME/webdata"`; do
+ chown root: $dir
+ chmod u+rw,go+r,a+X $dir
+ done
+ for dir in `find $HOME -mindepth 2 -maxdepth 2 -type d | egrep "^$HOME/webdata/"`; do
+ chown -R $user: $dir
+ chmod -R u=rw,go=r,a+X $webdir
+ done
# Dummy user restrictions
if [ -n "$DUMMYSHAREDIR" -a -n "$DUMMYSHAREOWNER" -a -n "$DUMMYSHARENAME" ]; then