WiX Burn 3.7 and Postgresql Registry Search fail - postgresql
I'm trying to build a bundle which with postgresql as prerequisite.
I'm trying to detect postgresql by searching into registry as follows:
<Fragment>
<util:RegistrySearch Id ="PostgresqlPath_x64"
Root="HKLM"
Key="SOFTWARE\PostgreSQL\Installations\postgresql-x64-9.1"
Result="exists"
Variable="PostgresqlInstalled_x64"
Win64="yes" />
<util:RegistrySearch Id="Postgresql_x86"
Root="HKLM"
Key="SOFTWARE\PostgreSQL\Installations\postgresql-9.1"
Result="exists"
Variable="PostgresqlInstalled_x86"
Win64="no"/>
and then use it in ExePackage:
<ExePackage SourceFile="..\..\bin\external_software\postgreSQL\postgresql-9.1.6-1-windows-x64.exe"
InstallCommand="$(var.PostgresqlInstallCommand)"
InstallCondition="VersionNT64"
DetectCondition="PostgresqlInstalled_x64"
PerMachine="yes"
Compressed="yes"/>
<ExePackage SourceFile="..\..\bin\external_software\postgreSQL\postgresql-9.1.6-1-windows.exe"
InstallCommand="$(var.PostgresqlInstallCommand)"
InstallCondition="(NOT VersionNT64)"
DetectCondition="PostgresqlInstalled_x86"
PerMachine="yes" Compressed="yes" />
It evaluates to false even when the Postgresql is installed, no matter on what Win Version (x86 or x64) I'm testing.
Am I doing anything wrong here or? :/
Here the compete log file of install:
[072C:0664][2013-10-08T15:32:15]i001: Burn v3.7.1224.0, Windows v6.1 (Build 7601: Service Pack 1), path: C:\Users\A521064\Desktop\sLIM_Bootstrapper.exe, cmdline: ''
[072C:0664][2013-10-08T15:32:15]i000: Initializing string variable 'PostgresqlUninstall' to value 'PostgreSQL\9.1\uninstall-postgresql.exe'
[072C:0664][2013-10-08T15:32:15]i000: Setting string variable 'WixBundleLog' to value 'C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215.log'
[072C:0664][2013-10-08T15:32:15]i000: Setting string variable 'WixBundleOriginalSource' to value 'C:\Users\A521064\Desktop\sLIM_Bootstrapper.exe'
[072C:0664][2013-10-08T15:32:15]i052: Condition 'VersionNT >= v5.1' evaluates to true.
[072C:0664][2013-10-08T15:32:15]i000: Setting string variable 'WixBundleName' to value 'sLIM Controller (Bundle)'
[072C:0664][2013-10-08T15:32:16]i100: Detect begin, 3 packages
[072C:0664][2013-10-08T15:32:16]i052: Condition 'PostgresqlInstalled_x64' evaluates to false.
[072C:0664][2013-10-08T15:32:16]i052: Condition 'PostgresqlInstalled_x86 OR PostgresqlInstalled_x86_2' evaluates to false.
[072C:0664][2013-10-08T15:32:16]i101: Detected package: postgresql_9.1.6_1_windows_x64.exe, state: Absent, cached: None
[072C:0664][2013-10-08T15:32:16]i101: Detected package: postgresql_9.1.6_1_windows.exe, state: Absent, cached: None
[072C:0664][2013-10-08T15:32:16]i101: Detected package: sLIMInstall.msi, state: Absent, cached: None
[072C:0664][2013-10-08T15:32:16]i199: Detect complete, result: 0x0
[072C:0664][2013-10-08T15:32:17]i200: Plan begin, 3 packages, action: Install
[072C:0664][2013-10-08T15:32:17]i052: Condition 'VersionNT64' evaluates to true.
[072C:0664][2013-10-08T15:32:17]w321: Skipping dependency registration on package with no dependency providers: postgresql_9.1.6_1_windows_x64.exe
[072C:0664][2013-10-08T15:32:17]i000: Setting string variable 'WixBundleLog_postgresql_9.1.6_1_windows_x64.exe' to value 'C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215_0_postgresql_9.1.6_1_windows_x64.exe.log'
[072C:0664][2013-10-08T15:32:17]i000: Setting string variable 'WixBundleRollbackLog_postgresql_9.1.6_1_windows_x64.exe' to value 'C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215_0_postgresql_9.1.6_1_windows_x64.exe_rollback.log'
[072C:0664][2013-10-08T15:32:17]i052: Condition '(NOT VersionNT64)' evaluates to false.
[072C:0664][2013-10-08T15:32:17]w321: Skipping dependency registration on package with no dependency providers: postgresql_9.1.6_1_windows.exe
[072C:0664][2013-10-08T15:32:17]i052: Condition 'VersionNT64 >= v5.1' evaluates to true.
[072C:0664][2013-10-08T15:32:17]i000: Setting string variable 'WixBundleRollbackLog_sLIMInstall.msi' to value 'C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215_1_sLIMInstall.msi_rollback.log'
[072C:0664][2013-10-08T15:32:17]i000: Setting string variable 'WixBundleLog_sLIMInstall.msi' to value 'C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215_1_sLIMInstall.msi.log'
[072C:0664][2013-10-08T15:32:17]i201: Planned package: postgresql_9.1.6_1_windows_x64.exe, state: Absent, default requested: Present, ba requested: Present, execute: Install, rollback: Uninstall, cache: Yes, uncache: No, dependency: None
[072C:0664][2013-10-08T15:32:17]i201: Planned package: postgresql_9.1.6_1_windows.exe, state: Absent, default requested: Absent, ba requested: Absent, execute: None, rollback: None, cache: No, uncache: No, dependency: None
[072C:0664][2013-10-08T15:32:17]i201: Planned package: sLIMInstall.msi, state: Absent, default requested: Present, ba requested: Present, execute: Install, rollback: Uninstall, cache: Yes, uncache: No, dependency: Register
[072C:0664][2013-10-08T15:32:17]i299: Plan complete, result: 0x0
[072C:0664][2013-10-08T15:32:17]i300: Apply begin
[0B08:0AB8][2013-10-08T15:32:20]i360: Creating a system restore point.
[0B08:0AB8][2013-10-08T15:32:33]i361: Created a system restore point.
[0B08:0AB8][2013-10-08T15:32:33]i000: Caching bundle from: 'C:\Users\A521064\AppData\Local\Temp\{cef60084-9565-4990-b3d6-2704a4475eab}\.be\sLIM_Bootstrapper.exe' to: 'C:\ProgramData\Package Cache\{cef60084-9565-4990-b3d6-2704a4475eab}\sLIM_Bootstrapper.exe'
[0B08:0AB8][2013-10-08T15:32:33]i320: Registering bundle dependency provider: {cef60084-9565-4990-b3d6-2704a4475eab}, version: 0.9.18.0
[0B08:0960][2013-10-08T15:32:39]i305: Verified acquired payload: postgresql_9.1.6_1_windows_x64.exe at path: C:\ProgramData\Package Cache\.unverified\postgresql_9.1.6_1_windows_x64.exe, moving to: C:\ProgramData\Package Cache\E8DC6F6A96D4A4821F149FA9CA67B35C506645C1\postgresql-9.1.6-1-windows-x64.exe.
[0B08:0960][2013-10-08T15:32:39]i305: Verified acquired payload: sLIMInstall.msi at path: C:\ProgramData\Package Cache\.unverified\sLIMInstall.msi, moving to: C:\ProgramData\Package Cache\{4E9DAE71-AC58-4A0C-A63F-2AC752C983EF}v0.9.19\sLIMInstall.msi.
[0B08:0AB8][2013-10-08T15:32:40]i301: Applying execute package: postgresql_9.1.6_1_windows_x64.exe, action: Install, path: C:\ProgramData\Package Cache\E8DC6F6A96D4A4821F149FA9CA67B35C506645C1\postgresql-9.1.6-1-windows-x64.exe, arguments: '"C:\ProgramData\Package Cache\E8DC6F6A96D4A4821F149FA9CA67B35C506645C1\postgresql-9.1.6-1-windows-x64.exe" --mode unattended --superpassword postgres --servicepassword postgres --debuglevel 4 --unattendedmodeui none --install_runtimes 0'
[072C:0664][2013-10-08T15:34:01]i319: Applied execute package: postgresql_9.1.6_1_windows_x64.exe, result: 0x0, restart: None
[0B08:0AB8][2013-10-08T15:34:01]i323: Registering package dependency provider: {4E9DAE71-AC58-4A0C-A63F-2AC752C983EF}, version: 0.9.19, package: sLIMInstall.msi
[0B08:0AB8][2013-10-08T15:34:01]i301: Applying execute package: sLIMInstall.msi, action: Install, path: C:\ProgramData\Package Cache\{4E9DAE71-AC58-4A0C-A63F-2AC752C983EF}v0.9.19\sLIMInstall.msi, arguments: ' ARPSYSTEMCOMPONENT="1" MSIFASTINSTALL="7"'
[072C:0664][2013-10-08T15:34:42]i319: Applied execute package: sLIMInstall.msi, result: 0x0, restart: None
[0B08:0AB8][2013-10-08T15:34:42]i325: Registering dependency: {cef60084-9565-4990-b3d6-2704a4475eab} on package provider: {4E9DAE71-AC58-4A0C-A63F-2AC752C983EF}, package: sLIMInstall.msi
[072C:0664][2013-10-08T15:34:42]i399: Apply complete, result: 0x0, restart: None, ba requested restart: No
[072C:0664][2013-10-08T15:34:45]i500: Shutting down, exit code: 0x0
[072C:0664][2013-10-08T15:34:45]i410: Variable: PostgresqlUninstall = PostgreSQL\9.1\uninstall-postgresql.exe
[072C:0664][2013-10-08T15:34:45]i410: Variable: VersionNT = 6.1.0.0
[072C:0664][2013-10-08T15:34:45]i410: Variable: VersionNT64 = 6.1.0.0
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleAction = 4
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleElevated = 1
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleInstalled = 0
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleLog = C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215.log
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleLog_postgresql_9.1.6_1_windows_x64.exe = C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215_0_postgresql_9.1.6_1_windows_x64.exe.log
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleLog_sLIMInstall.msi = C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215_1_sLIMInstall.msi.log
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleManufacturer = Atos IT Solutions and Services
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleName = sLIM Controller (Bundle)
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleOriginalSource = C:\Users\A521064\Desktop\sLIM_Bootstrapper.exe
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleProviderKey = {cef60084-9565-4990-b3d6-2704a4475eab}
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleRollbackLog_postgresql_9.1.6_1_windows_x64.exe = C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215_0_postgresql_9.1.6_1_windows_x64.exe_rollback.log
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleRollbackLog_sLIMInstall.msi = C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008153215_1_sLIMInstall.msi_rollback.log
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleTag =
[072C:0664][2013-10-08T15:34:45]i410: Variable: WixBundleVersion = 0.9.18.0
[072C:0664][2013-10-08T15:34:45]i007: Exit code: 0x0, restarting: No
And on Uninstall again it doesn't find the reg key:
[0AC0:05E0][2013-10-08T15:47:54]i001: Burn v3.7.1224.0, Windows v6.1 (Build 7601: Service Pack 1), path: C:\Users\A521064\Desktop\sLIM_Bootstrapper.exe, cmdline: ''
[0AC0:05E0][2013-10-08T15:47:54]i000: Initializing string variable 'PostgresqlUninstall' to value 'PostgreSQL\9.1\uninstall-postgresql.exe'
[0AC0:05E0][2013-10-08T15:47:54]i000: Setting string variable 'WixBundleLog' to value 'C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008154754.log'
[0AC0:05E0][2013-10-08T15:47:54]i000: Setting string variable 'WixBundleOriginalSource' to value 'C:\Users\A521064\Desktop\sLIM_Bootstrapper.exe'
[0AC0:05E0][2013-10-08T15:47:54]i052: Condition 'VersionNT >= v5.1' evaluates to true.
[0AC0:05E0][2013-10-08T15:47:54]i100: Detect begin, 3 packages
[0AC0:05E0][2013-10-08T15:47:54]i052: Condition 'PostgresqlInstalled_x64' evaluates to false.
[0AC0:05E0][2013-10-08T15:47:54]i052: Condition 'PostgresqlInstalled_x86 OR PostgresqlInstalled_x86_2' evaluates to false.
[0AC0:05E0][2013-10-08T15:47:54]i101: Detected package: postgresql_9.1.6_1_windows_x64.exe, state: Absent, cached: Complete
[0AC0:05E0][2013-10-08T15:47:54]i101: Detected package: postgresql_9.1.6_1_windows.exe, state: Absent, cached: None
[0AC0:05E0][2013-10-08T15:47:54]i101: Detected package: sLIMInstall.msi, state: Present, cached: Complete
[0AC0:05E0][2013-10-08T15:47:54]i199: Detect complete, result: 0x0
[0AC0:05E0][2013-10-08T15:48:07]i200: Plan begin, 3 packages, action: Uninstall
[0AC0:05E0][2013-10-08T15:48:07]i000: Setting string variable 'WixBundleRollbackLog_sLIMInstall.msi' to value 'C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008154754_0_sLIMInstall.msi_rollback.log'
[0AC0:05E0][2013-10-08T15:48:07]i000: Setting string variable 'WixBundleLog_sLIMInstall.msi' to value 'C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008154754_0_sLIMInstall.msi.log'
[0AC0:05E0][2013-10-08T15:48:07]w321: Skipping dependency registration on package with no dependency providers: postgresql_9.1.6_1_windows.exe
[0AC0:05E0][2013-10-08T15:48:07]w321: Skipping dependency registration on package with no dependency providers: postgresql_9.1.6_1_windows_x64.exe
[0AC0:05E0][2013-10-08T15:48:07]i201: Planned package: sLIMInstall.msi, state: Present, default requested: Absent, ba requested: Absent, execute: Uninstall, rollback: Install, cache: No, uncache: Yes, dependency: Unregister
[0AC0:05E0][2013-10-08T15:48:07]i201: Planned package: postgresql_9.1.6_1_windows.exe, state: Absent, default requested: Absent, ba requested: Absent, execute: None, rollback: None, cache: No, uncache: No, dependency: None
[0AC0:05E0][2013-10-08T15:48:07]i201: Planned package: postgresql_9.1.6_1_windows_x64.exe, state: Absent, default requested: Absent, ba requested: Absent, execute: None, rollback: None, cache: No, uncache: Yes, dependency: None
[0AC0:05E0][2013-10-08T15:48:07]i299: Plan complete, result: 0x0
[0AC0:05E0][2013-10-08T15:48:07]i300: Apply begin
[0600:0B3C][2013-10-08T15:48:09]i360: Creating a system restore point.
[0600:0B3C][2013-10-08T15:48:19]i361: Created a system restore point.
[0600:0B3C][2013-10-08T15:48:19]i326: Removed dependency: {cef60084-9565-4990-b3d6-2704a4475eab} on package provider: {4E9DAE71-AC58-4A0C-A63F-2AC752C983EF}, package sLIMInstall.msi
[0600:0B3C][2013-10-08T15:48:19]i329: Removed package dependency provider: {4E9DAE71-AC58-4A0C-A63F-2AC752C983EF}, package: sLIMInstall.msi
[0600:0B3C][2013-10-08T15:48:19]i301: Applying execute package: sLIMInstall.msi, action: Uninstall, path: C:\ProgramData\Package Cache\{4E9DAE71-AC58-4A0C-A63F-2AC752C983EF}v0.9.19\sLIMInstall.msi, arguments: ' ARPSYSTEMCOMPONENT="1" MSIFASTINSTALL="7"'
[0AC0:05E0][2013-10-08T15:48:22]i319: Applied execute package: sLIMInstall.msi, result: 0x0, restart: None
[0600:0B3C][2013-10-08T15:48:22]i351: Removing cached package: sLIMInstall.msi, from path: C:\ProgramData\Package Cache\{4E9DAE71-AC58-4A0C-A63F-2AC752C983EF}v0.9.19\
[0600:0B3C][2013-10-08T15:48:22]i351: Removing cached package: postgresql_9.1.6_1_windows_x64.exe, from path: C:\ProgramData\Package Cache\E8DC6F6A96D4A4821F149FA9CA67B35C506645C1\
[0600:0B3C][2013-10-08T15:48:22]i330: Removed bundle dependency provider: {cef60084-9565-4990-b3d6-2704a4475eab}
[0600:0B3C][2013-10-08T15:48:22]i352: Removing cached bundle: {cef60084-9565-4990-b3d6-2704a4475eab}, from path: C:\ProgramData\Package Cache\{cef60084-9565-4990-b3d6-2704a4475eab}\
[0AC0:05E0][2013-10-08T15:48:23]i399: Apply complete, result: 0x0, restart: None, ba requested restart: No
[0AC0:05E0][2013-10-08T15:48:43]i500: Shutting down, exit code: 0x0
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: PostgresqlUninstall = PostgreSQL\9.1\uninstall-postgresql.exe
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: VersionNT = 6.1.0.0
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleAction = 3
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleElevated = 1
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleInstalled = 1
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleLog = C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008154754.log
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleLog_sLIMInstall.msi = C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008154754_0_sLIMInstall.msi.log
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleManufacturer = Atos IT Solutions and Services
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleName = sLIM Controller (Bundle)
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleOriginalSource = C:\Users\A521064\Desktop\sLIM_Bootstrapper.exe
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleProviderKey = {cef60084-9565-4990-b3d6-2704a4475eab}
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleRollbackLog_sLIMInstall.msi = C:\Users\A521064\AppData\Local\Temp\sLIM_Controller_(Bundle)_20131008154754_0_sLIMInstall.msi_rollback.log
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleTag =
[0AC0:05E0][2013-10-08T15:48:43]i410: Variable: WixBundleVersion = 0.9.18.0
[0AC0:05E0][2013-10-08T15:48:43]i007: Exit code: 0x0, restarting: No
RegSearch from my MSI works:
<Property Id="POSTGRESQLX64">
<RegistrySearch Id='PostgresqlX64RegSearch'
Root='HKLM'
Key='SOFTWARE\PostgreSQL\Installations\postgresql-x64-9.1'
Name="Version"
Win64="yes"
Type ="raw" />
</Property>
And the log:
AppSearch: Property: POSTGRESQLX64, Signature: PostgresqlX64RegSearch
MSI (c) (08:4C) [15:34:04:011]: Note: 1: 2262 2: Signature 3: -2147287038
MSI (c) (08:4C) [15:34:04:011]: PROPERTY CHANGE: Adding POSTGRESQLX64 property. Its value is '9.1.6.1'.
AppSearch: Property: POSTGRESQL_SERVICE, Signature: PostgresqlServiceRegSearch
Burn is not calling either of your RegistrySearch elements because you've defined them in a <Fragment> but haven't referenced them in your <Bundle>.
You can do one of the following:
Add <util:RegistrySearchRef> elements inside your <Bundle>
Nest the <util:RegistrySearch> elements under <Bundle>
According to Rob Mensching in a mailing list post, referencing an item in a fragment with a <FoobarRef> element brings in the whole fragment:
When one thing is referenced in a Fragment the whole Fragment is pulled in.... The other elements you list are typically support elements so they can go in with some item that can be referenced. For example, the XxxSequence elements can go in a Fragment with the CustomAction being scheduled. Then you use a CustomActionRef to say, "Hey, I want that CustomAction and I don't want to think about how it gets scheduled."
When the <RegistrySearch> elements are being referenced, you'll see log entries like this:
[2218:2F1C][2013-10-09T10:59:02]i000: Setting numeric variable 'PostgresqlInstalled_x64' to value 0
Related
Issue running OpenSSL on Windows
I get the following error when I try to run the below code with openssl dependencies. Link to Code: https://github.com/TimonPost/udp-dtls Error: Compiling openssl-sys v0.9.72 error: failed to run custom build command for `openssl-sys v0.9.72` Caused by: process didn't exit successfully: `C:\Users\Administrator\Desktop\wintun-main\target\debug\build\openssl-sys-4454fbdd0966bbd8\build-script-main` (exit code: 101) --- stdout cargo:rustc-cfg=const_fn cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_LIB_DIR X86_64_PC_WINDOWS_GNU_OPENSSL_LIB_DIR unset cargo:rerun-if-env-changed=OPENSSL_LIB_DIR OPENSSL_LIB_DIR unset cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_INCLUDE_DIR X86_64_PC_WINDOWS_GNU_OPENSSL_INCLUDE_DIR unset cargo:rerun-if-env-changed=OPENSSL_INCLUDE_DIR OPENSSL_INCLUDE_DIR unset cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_DIR X86_64_PC_WINDOWS_GNU_OPENSSL_DIR unset cargo:rerun-if-env-changed=OPENSSL_DIR OPENSSL_DIR = C:\Users\Administrator\Desktop\wintun-main\OpenSSL-Win32 cargo:rustc-link-search=native=C:\Users\Administrator\Desktop\wintun-main\OpenSSL-Win32\lib cargo:include=C:\Users\Administrator\Desktop\wintun-main\OpenSSL-Win32\include cargo:rerun-if-changed=build/expando.c OPT_LEVEL = Some("0") TARGET = Some("x86_64-pc-windows-gnu") HOST = Some("x86_64-pc-windows-gnu") CC_x86_64-pc-windows-gnu = None CC_x86_64_pc_windows_gnu = None HOST_CC = None CC = None CFLAGS_x86_64-pc-windows-gnu = None CFLAGS_x86_64_pc_windows_gnu = None HOST_CFLAGS = None CFLAGS = None CRATE_CC_NO_DEFAULTS = None DEBUG = Some("true") CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2") running: "gcc.exe" "-O0" "-ffunction-sections" "-fdata-sections" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "C:\\Users\\Administrator\\Desktop\\wintun-main\\OpenSSL-Win32\\include" "-Wall" "-Wextra" "-E" "build/expando.c" exit code: 0 version: 3_0_2 cargo:rustc-cfg=osslconf="OPENSSL_NO_SSL3_METHOD" cargo:conf=OPENSSL_NO_SSL3_METHOD cargo:rustc-cfg=ossl300 cargo:rustc-cfg=ossl101 cargo:rustc-cfg=ossl102 cargo:rustc-cfg=ossl102f cargo:rustc-cfg=ossl102h cargo:rustc-cfg=ossl110 cargo:rustc-cfg=ossl110f cargo:rustc-cfg=ossl110g cargo:rustc-cfg=ossl110h cargo:rustc-cfg=ossl111 cargo:rustc-cfg=ossl111b cargo:rustc-cfg=ossl111c cargo:version_number=30000020 cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_LIBS X86_64_PC_WINDOWS_GNU_OPENSSL_LIBS unset cargo:rerun-if-env-changed=OPENSSL_LIBS OPENSSL_LIBS unset cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_STATIC cargo:rustc-cfg=ossl102f cargo:rustc-cfg=ossl102h cargo:rustc-cfg=ossl110 cargo:rustc-cfg=ossl110f cargo:rustc-cfg=ossl110g cargo:rustc-cfg=ossl110h cargo:rustc-cfg=ossl111 cargo:rustc-cfg=ossl111b cargo:rustc-cfg=ossl111c cargo:version_number=30000020 cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_LIBS X86_64_PC_WINDOWS_GNU_OPENSSL_LIBS unset cargo:rerun-if-env-changed=OPENSSL_LIBS OPENSSL_LIBS unset cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_STATIC cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_LIBS X86_64_PC_WINDOWS_GNU_OPENSSL_LIBS unset cargo:rerun-if-env-changed=OPENSSL_LIBS OPENSSL_LIBS unset cargo:rerun-if-env-changed=X86_64_PC_WINDOWS_GNU_OPENSSL_STATIC X86_64_PC_WINDOWS_GNU_OPENSSL_STATIC unset cargo:rerun-if-env-changed=OPENSSL_STATIC OPENSSL_STATIC unset --- stderr thread 'main' panicked at 'OpenSSL libdir at `C:\Users\Administrator\Desktop\wintun-main\OpenSSL-Win32\lib` does not contain the required files to either statically or dynamically link OpenSSL', C:\Users\Administrator\.cargo\registry\src\github.com-1ecc6299db9ec823\openssl-sys-0.9.72\build/main.rs:367:13 note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace I am not able to figure out what the issue is. I have installed openssl and mingw exe files and added paths to the environment variables as well as shown below.
I cloned your repo and was able to build it after a few steps. Below is what I did. Install openssl for windows using the following link: Win64 full install for software developers Make sure the following environment variable is set: OPENSSL_DIR=C:\Program Files\OpenSSL-Win64 Update the openssl cargo crate version to openssl = "0.10.38"
Rundeck stop running steps based on global variable
I have a Rundeck job that executes multiple steps, each of which are Job References to other small jobs. The first step selects a server to upgrade, and sets a global variable with the server name. The remaining steps perform upgrade tasks. It is possible though for the first step to return NONE as the server name, and if that's the case I would like to halt execution right there without running the remaining steps, and I'd like the whole job to be marked as Successful. I could just make that first job exit with an error code, but then the whole job looks failed, and it looks like there is something wrong with it, even though it successfully ran and found there was nothing to upgrade. Any ideas? I'm finding "use a flow control step" everywhere, but I can't see how to make that work for my use case.
The best way to create complex workflows depending on some output value is to use the Ruleset Strategy (Rundeck Enterprise). Take a look at this. On the community version you can save the result of the first step on a key-value variable and do some "script-fu" in the following steps: Step 1: print the status and save it on a data variable using the key-value data log filter. Steps 2,3,4: capture the key-value data and then the step can continue or not. I made an example easy to import to your instance for testing: - defaultTab: nodes description: '' executionEnabled: true id: 27de501a-8bb2-4c6e-a5f9-0676e80ca75a loglevel: INFO name: HelloWorld nodeFilterEditable: false options: - enforced: true name: opt1 required: true value: 'true' values: - 'true' - 'false' valuesListDelimiter: ',' plugins: ExecutionLifecycle: null scheduleEnabled: true sequence: commands: - exec: echo "url=${option.opt1}" plugins: LogFilter: - config: invalidKeyPattern: \s|\$|\{|\}|\\ logData: 'true' name: result regex: .*=\s*(.+)$ type: key-value-data - fileExtension: .sh interpreterArgsQuoted: false script: |- # data/value evaluation if [ "#data.result#" = "true" ]; then echo "step two" fi scriptInterpreter: /bin/bash - fileExtension: .sh interpreterArgsQuoted: false script: |- # data/value evaluation if [ "#data.result#" = "true" ]; then echo "step three" fi scriptInterpreter: /bin/bash - fileExtension: .sh interpreterArgsQuoted: false script: |- # data/value evaluation if [ "#data.result#" = "true" ]; then echo "step four" fi scriptInterpreter: /bin/bash keepgoing: false strategy: node-first uuid: 27de501a-8bb2-4c6e-a5f9-0676e80ca75a
MegaDrive68k's answer is what you can do best with the basic opensource version or if you have the Enterprise version. But you can also create your own plugin or make a fork out of an existing one. Which I did with the official flow control puglin and add conditions. You can fork this plugin and add in the java code 2 new #PluginProperty (That add two new field in a plugin parameter in rundeck interface) and make a comparison of values. Example: #PluginProperty(title = "First Value", description = "Compare this", required = true) String value1; #PluginProperty(title = "Second Value", description = "To this", required = true) String value2; Comparison of Strings values (in your case it is) if (value1.equals(value2)) {...} Comparison of Numeric values if (value1 == value2) {...} If you want to stop the job with successful (it does not stop the parent job, just actual): context.getFlowControl().Halt(true); If you want to stop the job with a failed status: context.getFlowControl().Halt(false); If you want to stop the job with a customized status: context.getFlowControl().Halt("MY CUSTOM STATUS"); And finally, if you want to continue and not stop: context.getFlowControl().Continue(); So a complete example (add this to your public class): #PluginProperty(title = "First Value", description = "Compare this", required = true) String value1; #PluginProperty(title = "Second Value", description = "To this", required = true) String value2; #Override public void executeStep(final PluginStepContext context, final Map<String, Object> configuration) throws StepException { if (value1.equals(value2)) { //Halt actual JOB without failed context.getFlowControl().Halt(true); } else { //Continue context.getFlowControl().Continue(); } } Then create your jar file and place it in the libext folder. Now you can add your custom step. Put your global var in the first field and "NONE" in the second field. If global var contain "NONE" the job stop successful at this step. If you call a job with this step from oterh job (parent), the parent job continue. If you want you can use this fork plugin which already includes these modifications. Look like this
readthedocs "virtualenv: error: unrecognized arguments" during update_repos
I have a local readthedocs installation at /readthedocs.org on a Debian buster container. Python 3.6 is installed along with the pip requirements (including virtualenv). I have a single repository added to readthedocs (Openwhisk) with the following basic config: # In .readthedocs.yml mkdocs: configuration: mkdocs.yml python: version: 3.6 system_packages: true # In mkdocs.yml site_name: Openwhisk When I run python3.6 manage.py update_repos I get the following error: [27/May/2020 19:00:01] readthedocs.doc_builder.environments:146[4964]: INFO Running: 'python3.6 -mvirtualenv /readthedocs.org/user_builds/openwhisk/envs/latest' [$HOME] [27/May/2020 19:00:01] readthedocs.doc_builder.environments:294[4964]: DEBUG Post response via JSON encoded data: {'id': 41, 'run_time': 0, 'command': 'python3.6 -mvirtualenv /readthedocs.org/user_builds/openwhisk/envs/latest', 'description': '', 'output': 'usage: virtualenv [--version] [--with-traceback] [-v | -q] [--app-data APP_DATA] [--clear-app-data] [--discovery {builtin}] [-p py] [--creator {builtin,cpython3-posix,venv}] [--seeder {app-data,pip}] [--no-seed]\n [--activators comma_sep_list] [--clear] [--system-site-packages] [--symlinks | --copies] [--download | --no-download] [--extra-search-dir d [d ...]] [--pip version] [--setuptools version] [--wheel version] [--no-pip]\n [--no-setuptools] [--no-wheel] [--symlink-app-data] [--prompt prompt] [-h]\n dest\nvirtualenv: error: unrecognized arguments: /readthedocs.org/user_builds/openwhisk/envs/latest', 'exit_code': 2, 'start_time': '2020-05-27T19:00:01.078364Z', 'end_time': '2020-05-27T19:00:01.326186Z', 'build': 7} [27/May/2020 19:00:01] readthedocs.vcs_support.utils:129[4964]: DEBUG Lock (openwhisk): Releasing [27/May/2020 19:00:01] readthedocs.doc_builder.environments:625[4964]: WARNING (Build) [openwhisk:latest] Command python3.6 -mvirtualenv /readthedocs.org/user_builds/openwhisk/envs/latest failed: usage: virtualenv [--version] [--with-traceback] [-v | -q] [--app-data APP_DATA] [--clear-app-data] [--discovery {builtin}] [-p py] [--creator {builtin,cpython3-posix,venv}] [--seeder {app-data,pip}] [--no-seed] [--activators comma_sep_list] [--clear] [--system-site-packages] [--symlinks | --copies] [--download | --no-download] [--extra-search-dir d [d ...]] [--pip version] [--setuptools version] [--wheel version] [--no-pip] [--no-setuptools] [--no-wheel] [--symlink-app-data] [--prompt prompt] [-h] dest virtualenv: error: unrecognized arguments: /readthedocs.org/user_builds/openwhisk/envs/latest Traceback (most recent call last): File "/readthedocs.org/readthedocs/projects/tasks.py", line 763, in run_build self.setup_python_environment() File "/readthedocs.org/readthedocs/projects/tasks.py", line 1139, in setup_python_environment self.python_env.setup_base() File "/readthedocs.org/readthedocs/doc_builder/python_environments.py", line 314, in setup_base cwd='$HOME', File "/readthedocs.org/readthedocs/doc_builder/environments.py", line 638, in run return super().run(*cmd, **kwargs) File "/readthedocs.org/readthedocs/doc_builder/environments.py", line 420, in run return self.run_command_class(cls=self.command_class, cmd=cmd, **kwargs) File "/readthedocs.org/readthedocs/doc_builder/environments.py", line 644, in run_command_class return super().run_command_class(*cmd, **kwargs) File "/readthedocs.org/readthedocs/doc_builder/environments.py", line 492, in run_command_class raise BuildEnvironmentWarning(msg) readthedocs.doc_builder.exceptions.BuildEnvironmentWarning: Command python3.6 -mvirtualenv /readthedocs.org/user_builds/openwhisk/envs/latest failed: usage: virtualenv [--version] [--with-traceback] [-v | -q] [--app-data APP_DATA] [--clear-app-data] [--discovery {builtin}] [-p py] [--creator {builtin,cpython3-posix,venv}] [--seeder {app-data,pip}] [--no-seed] [--activators comma_sep_list] [--clear] [--system-site-packages] [--symlinks | --copies] [--download | --no-download] [--extra-search-dir d [d ...]] [--pip version] [--setuptools version] [--wheel version] [--no-pip] [--no-setuptools] [--no-wheel] [--symlink-app-data] [--prompt prompt] [-h] dest virtualenv: error: unrecognized arguments: /readthedocs.org/user_builds/openwhisk/envs/latest [27/May/2020 19:00:01] readthedocs.doc_builder.environments:581[4964]: INFO (Build) [openwhisk:latest] Build finished [27/May/2020 19:00:01] celery.app.trace:124[4964]: INFO Task readthedocs.projects.tasks.send_notifications[508c1b76-28bf-4c97-9afd-5824295c378f] succeeded in 0.007888936903327703s: None [27/May/2020 19:00:01] readthedocs.projects.tasks:1450[4964]: INFO Skipping build files deletetion for version: 1 [27/May/2020 19:00:01] celery.app.trace:124[4964]: INFO Task readthedocs.projects.tasks.update_docs_task[bf8e5976-c70a-47b8-bf9c-69a31fbd9c24] succeeded in 4.51686664391309s: True The odd thing is when I run the exact same command from the CLI it works fine: root#38e93376269d:/readthedocs.org# python3.6 -mvirtualenv /readthedocs.org/user_builds/openwhisk/envs/latest created virtual environment CPython3.6.10.final.0-64 in 274ms creator CPython3Posix(dest=/readthedocs.org/user_builds/openwhisk/envs/latest, clear=False, global=False) seeder FromAppData(download=False, pip=latest, setuptools=latest, wheel=latest, via=copy, app_data_dir=/root/.local/share/virtualenv/seed-app-data/v1.0.1) activators BashActivator,CShellActivator,FishActivator,PowerShellActivator,PythonActivator,XonshActivator Any suggestions?
the use_system_site_packages: true key/value config has been removed and doesn't work anymore. use system_packages: true instead. python: version: 3.6 system_packages: true
To answer my own question: There's currently a bug with readthedocs 5.1 (and possibly older versions) where having use_system_site_packages set to false in .readthedocs.yml will give this error. To fix, put this in .readthedocs.yml: python: use_system_site_packages: true
The error is due to the way that Read the Docs invokes python -m virtualenv, which seems to cause issues with the building environment in some cases (but likely not for Docker environments). I can reproduce this with Debian Buster as well, and it is directly reproducible by adding an empty-string argument: python -mvirtualenv "" my_dest/ It is reported upstream, keep an eye out for a fix there: https://github.com/readthedocs/readthedocs.org/issues/7322
How can I skip a failing Rundeck job?
I have a Rundeck job to update servers using a custom script that is run as local command. If the server update needs to be postponed due to running jobs on it, the custom local command will return a special return code. The Rundeck job is configured to fail the step without running on any remaining nodes if a node fails. I want to skip a node and continue with the next node if this node return the special return code. I tried to experiment with an error handler using code like: /bin/sh -c 'if test "${result.resultCode}" = "125"; then exit 0; fi; exit "${result.resultCode}"' The stripped down job configuration looks like: - defaultTab: summary executionEnabled: true loglevel: INFO multipleExecutions: true name: Server update nodeFilterEditable: true nodefilters: dispatch: excludePrecedence: true keepgoing: false successOnEmptyNodeFilter: false threadcount: ${option.parallelity} filter: '' nodesSelectedByDefault: true notification: onfailure: email: recipients: me#example.com subject: 'rundeck: server update failed' onsuccess: email: recipients: me#example.com subject: 'rundeck: server update finished' notifyAvgDurationThreshold: null options: - description: Maximum number of server updates in parallel. name: parallelity regex: ^[0-9]+$ required: true value: '1' scheduleEnabled: true sequence: commands: - configuration: command: /usr/bin/custom-server-update "${node.name}" nodeStep: true type: localexec keepgoing: false strategy: parallel
At the moment of creating or edit your job scroll down and set this: If a node fails -> Continue running on any remaining nodes before failing the step.
cloudify custom workflow missing cloudify_agent runtime information
I want to develop my own workflow named "backup" in cloudify with my own plugin, but when i ran that workflow, the below error occured 'backup' workflow execution failed: RuntimeError: Workflow failed: Task failed 'script_runner.tasks.run' -> Missing cloudify_agent runtime information. This most likely means that the Compute node never started successfully I don't understand why, anybody can solved me this problem? Here is my main blueprint code and plugin code My main blueprint tosca_definitions_version: cloudify_dsl_1_2 imports: - plugins/backup.yaml - types/types.yaml node_templates: mynode: type: cloudify.nodes.Compute properties: ip: "ip" agent_config: install_method: none user: "user" key: "key_uri" myapp: type: cloudify.nodes.ApplicationModule interfaces: test_platform_backup: backup: implementation: scripts/backup.sh inputs: port: 6969 post_backup: implementation: scripts/post_backup.sh relationships: - type: cloudify.relationships.contained_in target: mynode My plugin code: from cloudify.decorators import workflow from cloudify.workflows import ctx from cloudify.workflows.tasks_graph import forkjoin #workflow def backup(operation, type_name, operation_kwargs, is_node_operation, **kwargs): graph = ctx.graph_mode() send_event_starting_tasks = {} send_event_done_tasks = {} for node in ctx.nodes: if type_name in node.type_hierarchy: for instance in node.instances: send_event_starting_tasks[instance.id] = instance.send_event('Starting to run operation') send_event_done_tasks[instance.id] = instance.send_event('Done running operation') for node in ctx.nodes: if type_name in node.type_hierarchy: for instance in node.instances: sequence = graph.sequence() if is_node_operation: operation_task = instance.execute_operation(operation, kwargs=operation_kwargs) else: forkjoin_tasks = [] for relationship in instance.relationships: forkjoin_tasks.append(relationship.execute_source_operation(operation)) forkjoin_tasks.append(relationship.execute_target_operation(operation)) operation_task = forkjoin(*forkjoin_tasks) sequence.add( send_event_starting_tasks[instance.id], operation_task, send_event_done_tasks[instance.id]) for node in ctx.nodes: for instance in node.instances: for rel in instance.relationships: instance_starting_task = send_event_starting_tasks.get(instance.id) target_done_task = send_event_done_tasks.get(rel.target_id) if instance_starting_task and target_done_task: graph.add_dependency(instance_starting_task, target_done_task) return graph.execute()
It seems that your VM did not start. From your code I can't understand what you are trying to do. You don't install and agent and you don't have a fabric connection to the VM, yet you are trying to run operations on the VM. You should either install an agent, E.g remove the "install_method: none", or add a fabric connection to the VM and run the operations with it.