summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorroot2016-02-18 14:35:25 +0100
committerroot2016-02-18 14:35:25 +0100
commitc7a50be52d883b1618096a30f870836ede714735 (patch)
treea09519545f2b0e1ff6af127865be5fe20872faa8
parent[dnbd3] Include dnbd3-fuse (diff)
parent[cron] Fix path when copying crond binary (diff)
downloadtm-scripts-c7a50be52d883b1618096a30f870836ede714735.tar.gz
tm-scripts-c7a50be52d883b1618096a30f870836ede714735.tar.xz
tm-scripts-c7a50be52d883b1618096a30f870836ede714735.zip
Merge branch 'master' of git://git.openslx.org/openslx-ng/tm-scripts
-rw-r--r--remote/modules/cron/module.build2
-rwxr-xr-xremote/modules/run-virt/compile5
-rwxr-xr-xremote/modules/run-virt/data/opt/openslx/vmchooser/data/openslx.exebin15360 -> 15360 bytes
-rw-r--r--remote/modules/run-virt/winres.c13
-rw-r--r--server/modules/auth-freiburg/opt/openslx/scripts/pam_script_mount_persistent3
5 files changed, 17 insertions, 6 deletions
diff --git a/remote/modules/cron/module.build b/remote/modules/cron/module.build
index cf696ea0..d9f1e825 100644
--- a/remote/modules/cron/module.build
+++ b/remote/modules/cron/module.build
@@ -21,7 +21,7 @@ build() {
# NO MAKE INSTALL: Copy to build dir, since there are no shared libs linked in
mkdir -p "${MODULE_BUILD_DIR}/opt/openslx/sbin"
- cp "${MODULE_DIR}/src/crond" "${MODULE_BUILD_DIR}/opt/openslx/sbin/" || perror "Could copy crond binary to ${MODULE_BUILD_DIR}"
+ cp "${MODULE_DIR}/src/src/crond" "${MODULE_BUILD_DIR}/opt/openslx/sbin/" || perror "Could not copy crond binary to ${MODULE_BUILD_DIR}"
cd - &>/dev/null
}
diff --git a/remote/modules/run-virt/compile b/remote/modules/run-virt/compile
new file mode 100755
index 00000000..4db15686
--- /dev/null
+++ b/remote/modules/run-virt/compile
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+rm -- winres.exe
+i686-w64-mingw32-gcc -std=c99 -Os -Wl,--subsystem,windows -o winres.exe winres.c -lole32 -luuid -lgdi32 #-lws2_32
+strip winres.exe && echo "Successfully created winres.exe"
diff --git a/remote/modules/run-virt/data/opt/openslx/vmchooser/data/openslx.exe b/remote/modules/run-virt/data/opt/openslx/vmchooser/data/openslx.exe
index a1616798..114a0dc0 100755
--- a/remote/modules/run-virt/data/opt/openslx/vmchooser/data/openslx.exe
+++ b/remote/modules/run-virt/data/opt/openslx/vmchooser/data/openslx.exe
Binary files differ
diff --git a/remote/modules/run-virt/winres.c b/remote/modules/run-virt/winres.c
index a9037b61..c9065c03 100644
--- a/remote/modules/run-virt/winres.c
+++ b/remote/modules/run-virt/winres.c
@@ -51,15 +51,18 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine
// Mute sound by default
if (retVer && version.dwMajorVersion >= 6)
muteSound();
+ // Disable screen saver as it might give the false impression that the session is securely locked
+ SystemParametersInfo(SPI_SETSCREENSAVEACTIVE, FALSE, NULL, 0);
+ // Disable standby and idle-mode (this is a VM!)
+ if (version.dwMajorVersion >= 6) { // Vista+
+ SetThreadExecutionState(ES_CONTINUOUS | ES_SYSTEM_REQUIRED | ES_DISPLAY_REQUIRED | ES_AWAYMODE_REQUIRED);
+ } else { // XP/2003
+ SetThreadExecutionState(ES_CONTINUOUS | ES_SYSTEM_REQUIRED | ES_DISPLAY_REQUIRED);
+ }
// Shutdown button label
if (retVer && version.dwMajorVersion == 6 && version.dwMinorVersion == 1) {
// Only on Windows 7
char buffer[100];
- ret = setShutdownText();
- if (ret != 0) {
- snprintf(buffer, 100, "Returned %d", ret);
- MessageBoxA(0, buffer, "Set caption", 0);
- }
// Repeatedly set caption
UINT_PTR tRet = SetTimer(NULL, 0, 5000, (TIMERPROC)&resetShutdown);
if (tRet == 0) {
diff --git a/server/modules/auth-freiburg/opt/openslx/scripts/pam_script_mount_persistent b/server/modules/auth-freiburg/opt/openslx/scripts/pam_script_mount_persistent
index dbe6ef01..d6a6d02c 100644
--- a/server/modules/auth-freiburg/opt/openslx/scripts/pam_script_mount_persistent
+++ b/server/modules/auth-freiburg/opt/openslx/scripts/pam_script_mount_persistent
@@ -6,6 +6,9 @@
# It will try to mount the home directories of students
# under /home/<user>/PERSISTENT using cifs/kerberos.
#
+# If cifs mount fails, nfs mount will be tried.
+#
+###################################################################
# Only run this if PAM_USER is not a local user.
if ! grep -q "^${PAM_USER}:" "/etc/passwd"; then