summaryrefslogtreecommitdiffstats
path: root/remote
diff options
context:
space:
mode:
authorJonathan Bauer2015-10-22 13:53:45 +0200
committerJonathan Bauer2015-10-22 13:53:45 +0200
commit98bb0b12a60fa729908e6f8120b35954bc821cb1 (patch)
tree672fb7bd75e345d2817c132174ffafa044fadb4b /remote
parent[redsocks] if proxy mode is on, checks whether we actually need it to reach t... (diff)
parent[vmware] Unneeded file (diff)
downloadtm-scripts-98bb0b12a60fa729908e6f8120b35954bc821cb1.tar.gz
tm-scripts-98bb0b12a60fa729908e6f8120b35954bc821cb1.tar.xz
tm-scripts-98bb0b12a60fa729908e6f8120b35954bc821cb1.zip
Merge branch 'master' of git.openslx.org:openslx-ng/tm-scripts
Diffstat (limited to 'remote')
-rw-r--r--remote/modules/dnbd3/module.conf2
-rwxr-xr-xremote/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store25
-rw-r--r--remote/modules/vmware/data/opt/openslx/vmchooser/vmware/includes/create_vmhome_preferences_file.inc6
-rw-r--r--remote/modules/vmware/module.build8
-rw-r--r--remote/modules/vmware/templates/vmware/config24
5 files changed, 31 insertions, 34 deletions
diff --git a/remote/modules/dnbd3/module.conf b/remote/modules/dnbd3/module.conf
index 631b0e23..a0729107 100644
--- a/remote/modules/dnbd3/module.conf
+++ b/remote/modules/dnbd3/module.conf
@@ -2,7 +2,7 @@
#REQUIRED_CONTENT_PACKAGES="libgconf-2-4 fontconfig-config"
REQUIRED_MODULES="kernel"
REQUIRED_GIT="git://git.openslx.org/dnbd3.git"
-REQUIRED_COMMIT="bc4ee543ce5beec823ae0cbd811bb7febe43103f"
+REQUIRED_COMMIT="c3c050851dc866f2311d33a262ed81af8c57ce22"
REQUIRED_BINARIES="
dnbd3-client
"
diff --git a/remote/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store b/remote/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store
index 5e1ebf43..4559e1e3 100755
--- a/remote/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store
+++ b/remote/modules/run-virt/data/opt/openslx/scripts/systemd-mount_vm_store
@@ -2,19 +2,38 @@
. /opt/openslx/config || exit 1
-[ -z "$SLX_VM_NFS" ] && slxlog "mount-vmstore" "No SLX_VM_NFS given in /opt/openslx/config!" && exit 1
+[ -z "$SLX_VM_NFS" ] && slxlog "mount-vmstore-missing" "No SLX_VM_NFS given in /opt/openslx/config!" && exit 1
# create target directory
mkdir -p /mnt/vmstore
+OUTFILE=$(mktemp)
+
# check if it is a CIFS-share or NFS-share
# no bash, so this is a bit ugly...
if [ "${SLX_VM_NFS#//}" = "${SLX_VM_NFS}" ]; then
# doesn't start with '//' -> assume NFS
- mount -t nfs -o ro,async,nolock "$SLX_VM_NFS" /mnt/vmstore
+ /opt/openslx/bin/timeout -t 10 -s 9 mount -v -t nfs -o ro,async,nolock "$SLX_VM_NFS" /mnt/vmstore
+ RET=$?
else
# starts with '//' -> assume CIFS
export USER="$SLX_VM_NFS_USER"
export PASSWD="$SLX_VM_NFS_PASSWD"
- mount -t cifs -o ro,file_mode=0644,dir_mode=0755,uid=0,gid=0,forceuid,forcegid,sec=ntlm,nounix "$SLX_VM_NFS" /mnt/vmstore
+ /opt/openslx/bin/timeout -t 10 -s 9 mount -v -t cifs -o ro,file_mode=0644,dir_mode=0755,uid=0,gid=0,forceuid,forcegid,sec=ntlm,nounix "$SLX_VM_NFS" /mnt/vmstore
+ unset USER
+ unset PASSWD
+ RET=$?
+fi > "$OUTFILE" 2>&1
+
+if [ $RET -ne 0 ]; then
+ if [ -s "$OUTFILE" ]; then
+ slxlog "mount-vmstore-fail" "Mounting '$SLX_VM_NFS' failed. VMs will not boot." "$OUTFILE"
+ sleep 1
+ else
+ slxlog "mount-vmstore-fail" "Mounting '$SLX_VM_NFS' failed. VMs will not boot."
+ fi
fi
+
+rm -f -- "$OUTFILE"
+exit $RET
+
diff --git a/remote/modules/vmware/data/opt/openslx/vmchooser/vmware/includes/create_vmhome_preferences_file.inc b/remote/modules/vmware/data/opt/openslx/vmchooser/vmware/includes/create_vmhome_preferences_file.inc
index c084f224..e33320ad 100644
--- a/remote/modules/vmware/data/opt/openslx/vmchooser/vmware/includes/create_vmhome_preferences_file.inc
+++ b/remote/modules/vmware/data/opt/openslx/vmchooser/vmware/includes/create_vmhome_preferences_file.inc
@@ -10,12 +10,6 @@ create_vmhome_preferences_file() {
pref.downloadPermission = "DENY"
pref.vmplayer.downloadPermission = "DENY"
pref.vmplayer.webUpdateOnStartup = "FALSE"
- pref.autoSoftwareUpdatePermission = "deny"
- pref.componentDownloadPermission = "deny"
- pref.dataCollectionEnabled.epoch = "5828812105"
- pref.vmplayer.dataCollectionEnabled = "FALSE"
- pref.autoSoftwareUpdatePermission.epoch = "6559291604"
- pref.componentDownloadPermission.epoch = ""
pref.lastUpdateCheckSec = "$(date +%s)"
# hints
pref.tip.startup = "FALSE"
diff --git a/remote/modules/vmware/module.build b/remote/modules/vmware/module.build
index 71df1432..878e1b59 100644
--- a/remote/modules/vmware/module.build
+++ b/remote/modules/vmware/module.build
@@ -111,6 +111,14 @@ build() {
vmware_build=${BUILD_VERSION}
maxhardwareversion=${OFFICIAL_VERSION%%.*}
EOF
+
+ # Patch system-wide vmware config
+ sed -i '/^installerDefaults.autoSoftwareUpdateEnabled/d;/^installerDefaults.componentDownloadEnabled/d;/^installerDefaults.dataCollectionEnabled/d' "${MODULE_BUILD_DIR}/etc/vmware/config"
+ cat >> "${MODULE_BUILD_DIR}/etc/vmware/config" <<-HEREDOC
+ installerDefaults.autoSoftwareUpdateEnabled = "no"
+ installerDefaults.componentDownloadEnabled = "no"
+ installerDefaults.dataCollectionEnabled = "no"
+ HEREDOC
}
post_copy() {
diff --git a/remote/modules/vmware/templates/vmware/config b/remote/modules/vmware/templates/vmware/config
deleted file mode 100644
index d8420e0d..00000000
--- a/remote/modules/vmware/templates/vmware/config
+++ /dev/null
@@ -1,24 +0,0 @@
-.encoding = "UTF-8"
-installerDefaults.componentDownloadEnabled = "no"
-installerDefaults.dataCollectionEnabled = "no"
-installerDefaults.transferVersion = "1"
-installerDefaults.autoSoftwareUpdateEnabled = "no"
-NETWORKING = "yes"
-VMBLOCK_CONFED = "yes"
-VMCI_CONFED = "yes"
-VSOCK_CONFED = "yes"
-gksu.rootMethod = "sudo"
-MemTrimRate = "0"
-prefvmx.minVmMemPct = "100"
-prefvmx.useRecommendedLockedMemSize = "TRUE"
-libdir = "/usr/lib/vmware"
-mks.ctlAltDel.ignore = "TRUE"
-mks.fullscreen.allowScreenSaver = "TRUE"
-fullScreenSwitch.onSeparateDesktop = "TRUE"
-msg.autoAnswer = "TRUE"
-authd.fullpath = "/usr/sbin/vmware-authd"
-bindir = "/usr/bin"
-vix.config.version = "1"
-player.product.version = "%PLAYER_VERSION%"
-product.buildNumber = "%BUILD_NUMBER%"
-