Add regular user to dialout group for Stellarium
[hvlinux.git] / stage5 / post-install
index 3086b3a..383ab6e 100755 (executable)
@@ -8,7 +8,9 @@ if [ -n "${REGUSER}" ]; then
     hv_useradd -g users -s /bin/bash -m ${REGUSER}
 
     # Add user to these supplementary groups:
-    usermod -a -G audio,video,cdrom,usb,shutdown ${REGUSER}
+    usermod -a -G \
+            audio,dialout,video,cdrom,usb,shutdown,kvm,lp,lpadmin,scanner,plugdev \
+            ${REGUSER}
 fi
 
 if [ "x${INST_TYPE}" = "xserver" -o "x${INST_TYPE}" = "xltsp-server" ]; then
@@ -16,22 +18,24 @@ if [ "x${INST_TYPE}" = "xserver" -o "x${INST_TYPE}" = "xltsp-server" ]; then
     #########################################
     # Apache
     #########################################
-    READ_VALID="no"
-
-    while [ "${READ_VALID}" = "no" ]; do
-       echo "Do you want to generate SSL self-signed"
-       echo -n "certificate for Apache? (y/n): "
-       read USE_SSL
-
-       if [ "${USE_SSL}" = "y" -o "${USE_SSL}" = "n" ]; then
-           READ_VALID="yes"
-       else
-           echo "Error, answer y or n"
-       fi
-    done
-
-    if [ "${USE_SSL}" = "y" ]; then
-       /etc/apache/generate-ssl-certs
+    if [ "x${USE_HTTPD}" = "xyes" ]; then
+        READ_VALID="no"
+
+        while [ "${READ_VALID}" = "no" ]; do
+           echo "Do you want to generate SSL self-signed"
+           echo -n "certificate for Apache? (y/n): "
+           read USE_SSL
+
+           if [ "${USE_SSL}" = "y" -o "${USE_SSL}" = "n" ]; then
+               READ_VALID="yes"
+           else
+               echo "Error, answer y or n"
+           fi
+        done
+
+        if [ "${USE_SSL}" = "y" ]; then
+           /etc/httpd/generate-ssl-certs
+        fi
     fi
 
     #########################################