Changeset 1137 for opsi/products/wsusoffline/CLIENT_DATA
- Timestamp:
- Jan 24, 2013, 3:07:03 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
opsi/products/wsusoffline/CLIENT_DATA/setup.ins
r995 r1137 5 5 6 6 [Actions] 7 requiredWinstVersion >= "4.10.8.6" 7 ; at least 4.11.2, tested with 4.11.3.3 8 requiredWinstVersion >= "4.11.3.3" 8 9 9 10 DefVar $MsiId32$ … … 47 48 Set $MinimumSpace$ = "300 MB" 48 49 ; the path were we find the product after the installation 49 Set $InstallDir32$ = "%ProgramFiles32Dir%\<path to the product>"50 Set $InstallDir64$ = "%ProgramFiles64Dir%\<path to the product>"51 Set $LicenseRequired$ = "false"52 Set $LicensePool$ = "p_" + $ProductId$50 ;Set $InstallDir32$ = "%ProgramFiles32Dir%\<path to the product>" 51 ;Set $InstallDir64$ = "%ProgramFiles64Dir%\<path to the product>" 52 ;Set $LicenseRequired$ = "false" 53 ;Set $LicensePool$ = "p_" + $ProductId$ 53 54 ; ---------------------------------------------------------------- 54 55 … … 57 58 isFatalError 58 59 ; Stop process and set installation status to failed 59 else60 comment "Show product picture"61 ShowBitmap "%ScriptPath%\" + $ProductId$ + ".png" $ProductId$62 63 ;if FileExists("%ScriptPath%\delsub3264.ins")64 ; comment "Start uninstall sub section"65 ; Sub "%ScriptPath%\delsub3264.ins"66 ;endif67 68 ;if $LicenseRequired$ = "true"69 ; comment "Licensing required, reserve license and get license key"70 ; Sub_get_licensekey71 ;endif72 73 comment "installing"74 75 Message "Installing " + $ProductId$ + " ..."76 comment "Start setup program"77 Winbatch_install78 Sub_check_exitcode79 ;comment "Copy files"80 ;Files_install_32 /32Bit81 ;comment "Patch Registry"82 ;Registry_install /32Bit83 ;comment "Create shortcuts"84 ;LinkFolder_install85 86 60 endif 87 61 88 [Winbatch_install] 89 "%ScriptPath%\exit-wrapper.cmd" "%ScriptPath%\client\cmd\DoUpdate.cmd" $Options$ 62 comment "Show product picture" 63 ShowBitmap "%ScriptPath%\" + $ProductId$ + ".png" $ProductId$ 64 65 ;if FileExists("%ScriptPath%\delsub3264.ins") 66 ; comment "Start uninstall sub section" 67 ; Sub "%ScriptPath%\delsub3264.ins" 68 ;endif 69 70 comment "installing" 71 Message "Installing " + $ProductId$ + " ..." 72 73 comment "Start setup program" 74 ;Winbatch_install 75 Shellbatch_install /sysnative 76 77 ; include wsusoffline logfile (last 1000 lines) 78 includelog "%Systemroot%\wsusofflineupdate.log" "1000" 79 80 ; check exit code, reboot is required 81 Sub_check_exitcode 82 83 ;comment "Copy files" 84 ;Files_install_32 /32Bit 85 ;comment "Patch Registry" 86 ;Registry_install /32Bit 87 88 89 90 ;[Winbatch_install] 91 ;"%ScriptPath%\exit-wrapper.cmd" "%ScriptPath%\client\cmd\DoUpdate.cmd" $Options$ 92 93 94 95 [ShellBatch_install] 96 @rem remove old wsusoffline logfile 97 del /q "%Systemroot%\wsusofflineupdate.log" 98 call "%ScriptPath%\client\cmd\DoUpdate.cmd" $Options$ 99 exit %ERRORLEVEL% 100 90 101 91 102 … … 102 113 ; set "name2" = REG_DWORD:0001 103 114 ; set "name3" = REG_BINARY:00 af 99 cd 104 105 [LinkFolder_install]106 ; Example of deleting a folder from AllUsers startmenu:107 ;108 ; set_basefolder common_programs109 ; delete_subfolder $ProductId$110 ;111 ; Example of creating an shortcut to the installed exe in AllUsers startmenu:112 ;113 ; set_basefolder common_programs114 ; set_subfolder $ProductId$115 ;116 ; set_link117 ; name: $ProductId$118 ; target: <path to the program>119 ; parameters:120 ; working_dir: $InstallDir$121 ; icon_file:122 ; icon_index:123 ; end_link124 ;125 ; Example of creating an shortcut to the installed exe on AllUsers desktop:126 ;127 ; set_basefolder common_desktopdirectory128 ; set_subfolder ""129 ;130 ; set_link131 ; name: $ProductId$132 ; target: <path to the program>133 ; parameters: <some_param>134 ; working_dir: $InstallDir$135 ; icon_file: <path to icon file>136 ; icon_index: 2137 ; end_link138 139 [Sub_get_licensekey]140 comment "License management is enabled and will be used"141 142 comment "Trying to get a license key"143 Set $LicenseKey$ = demandLicenseKey ($LicensePool$)144 ; If there is an assignment of exactly one licensepool to the product the following call is possible:145 ; Set $LicenseKey$ = demandLicenseKey ("", $ProductId$)146 ;147 ; If there is an assignment of a license pool to a windows software id, it is possible to use:148 ; DefVar $WindowsSoftwareId$149 ; $WindowsSoftwareId$ = "..."150 ; Set $LicenseKey$ = demandLicenseKey ("", "", $WindowsSoftwareId$)151 152 DefVar $ServiceErrorClass$153 set $ServiceErrorClass$ = getLastServiceErrorClass154 comment "Error class: " + $ServiceErrorClass$155 156 if $ServiceErrorClass$ = "None"157 comment "Everything fine, we got the license key '" + $LicenseKey$ + "'"158 else159 if $ServiceErrorClass$ = "LicenseConfigurationError"160 LogError "Fatal: license configuration must be corrected"161 LogError getLastServiceErrorMessage162 isFatalError163 else164 if $ServiceErrorClass$ = "LicenseMissingError"165 LogError "Fatal: required license is not supplied"166 isFatalError167 endif168 endif169 endif170 171 115 172 116
Note:
See TracChangeset
for help on using the changeset viewer.