[debian-edu-commits] debian-edu/ 08/18: Change home directory of guacd.
Dominik George
natureshadow-guest at moszumanska.debian.org
Fri Oct 7 18:49:29 UTC 2016
This is an automated email from the git hooks/post-receive script.
natureshadow-guest pushed a commit to branch master
in repository guacamole-server.
commit 4f1e5a9dc3fd9aaa602a991c6cd5e644bacea8f9
Author: Dominik George <nik at naturalnet.de>
Date: Fri Oct 7 16:40:16 2016 +0200
Change home directory of guacd.
---
debian/guacd.dirs | 1 -
debian/guacd.postinst | 26 ++------------------------
2 files changed, 2 insertions(+), 25 deletions(-)
diff --git a/debian/guacd.dirs b/debian/guacd.dirs
deleted file mode 100644
index 315b4f2..0000000
--- a/debian/guacd.dirs
+++ /dev/null
@@ -1 +0,0 @@
-/usr/share/guacd
diff --git a/debian/guacd.postinst b/debian/guacd.postinst
index e91eb21..36a1bad 100644
--- a/debian/guacd.postinst
+++ b/debian/guacd.postinst
@@ -2,8 +2,7 @@
#
# Simple postinst script for guacd which creates a "guacd" user and group
# and sets the permissions and ownership of /var/run/guacd (the location
-# of the guacd.pid file) and /usr/share/guacd (the home directory of the
-# guacd user).
+# of the guacd.pid file).
#
@@ -12,7 +11,7 @@ set -e
GUACD_USER="guacd" # guacd username
GUACD_GROUP="guacd" # guacd group
-GUACD_HOME="/usr/share/guacd" # guacd home directory
+GUACD_HOME="/var/run/guacd" # guacd home directory
# Convenience function for error conditions.
fail() {
@@ -20,23 +19,6 @@ fail() {
exit 1
}
-# Convenience function for setting ownership and permissions of files while
-# failing cleanly.
-set_perms() {
-
- FILE="$1"
- PERMS="$2"
-
- # Update ownership
- chown "$GUACD_USER:$GUACD_GROUP" $FILE ||\
- fail "Unable to change ownership of $FILE"
-
- # Update permissions
- chmod "$PERMS" $FILE ||\
- fail "Unable to change permissions of $FILE"
-
-}
-
# Create guacd group if it does not exist
groupadd -fr "$GUACD_GROUP" ||\
fail "Could not create group \"$GUACD_GROUP\""
@@ -49,11 +31,7 @@ useradd -g "$GUACD_GROUP" -d "$GUACD_HOME" -s /bin/false -r "$GUACD_USER" || (
fi
)
-# Home directory should only be readable by guacd.
-set_perms "$GUACD_HOME" 700
-
#DEBHELPER#
# Exit successfully
exit 0
-
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-edu/pkg-team/guacamole-server.git
More information about the debian-edu-commits
mailing list