Intial package
This commit is contained in:
commit
a002fcbcfa
0
CLIENT_DATA/client/empty
Normal file
0
CLIENT_DATA/client/empty
Normal file
115
CLIENT_DATA/setup.ins
Normal file
115
CLIENT_DATA/setup.ins
Normal file
@ -0,0 +1,115 @@
|
|||||||
|
; Copyright (c) uib gmbh (www.uib.de)
|
||||||
|
; This sourcecode is owned by uib
|
||||||
|
; and published under the Terms of the General Public License.
|
||||||
|
; credits: http://www.opsi.org/credits/
|
||||||
|
|
||||||
|
[Actions]
|
||||||
|
; at least 4.11.2, tested with 4.11.3.3
|
||||||
|
requiredWinstVersion >= "4.11.3.3"
|
||||||
|
|
||||||
|
DefVar $LogDir$
|
||||||
|
DefVar $ProductId$
|
||||||
|
DefVar $MinimumSpace$
|
||||||
|
DefVar $ExitCode$
|
||||||
|
DefVar $INST_SystemType$
|
||||||
|
DefVar $INST_architecture$
|
||||||
|
|
||||||
|
Set $INST_SystemType$ = GetSystemType
|
||||||
|
|
||||||
|
;
|
||||||
|
; get product properties for options
|
||||||
|
;
|
||||||
|
; multi-value values are return as string, seperated by ",", eg. "value1,value2,value3",
|
||||||
|
; therefore we replace "," by " " (split, compose)
|
||||||
|
;
|
||||||
|
DefVar $Options$
|
||||||
|
Set $Options$ = composeString( splitString ( GetProductProperty("options",""), "," ), " " )
|
||||||
|
|
||||||
|
comment "options: " + $Options$
|
||||||
|
|
||||||
|
Set $LogDir$ = "%SystemDrive%\tmp"
|
||||||
|
|
||||||
|
; The token BUILDER_VARIABLES will be replaced by opsi-builder.sh
|
||||||
|
; and adds the following variables:
|
||||||
|
; from builder-product.cfg : all variables definded by attribute WINST[index]
|
||||||
|
; from builder-product.cfg : VENDOR PN VERSION RELEASE PRIORITY ADVICE TYPE
|
||||||
|
; from opsi-builder.cfg : CREATOR_TAG CREATOR_NAME CREATOR_EMAIL
|
||||||
|
; auto generated winst-variables
|
||||||
|
; $IconFile$: path to product picture
|
||||||
|
;
|
||||||
|
@@BUILDER_VARIABLES@@
|
||||||
|
|
||||||
|
; ----------------------------------------------------------------
|
||||||
|
; - Please edit the following values -
|
||||||
|
; ----------------------------------------------------------------
|
||||||
|
;$ProductId$ should be the name of the product in opsi
|
||||||
|
; therefore please: only lower letters, no umlauts,
|
||||||
|
; no white space use '-' as a seperator
|
||||||
|
Set $MinimumSpace$ = "1000 MB"
|
||||||
|
; ----------------------------------------------------------------
|
||||||
|
|
||||||
|
if not(HasMinimumSpace ("%SystemDrive%", $MinimumSpace$))
|
||||||
|
LogError "Not enough space on %SystemDrive%, " + $MinimumSpace$ + " on drive %SystemDrive% needed for " + $ProductId$
|
||||||
|
isFatalError
|
||||||
|
; Stop process and set installation status to failed
|
||||||
|
endif
|
||||||
|
|
||||||
|
comment "Show product picture"
|
||||||
|
ShowBitmap "%ScriptPath%\" + $ProductId$ + ".png" $ProductId$
|
||||||
|
|
||||||
|
comment "installing"
|
||||||
|
Message "Installing " + $ProductId$ + " ..."
|
||||||
|
|
||||||
|
comment "Start setup program"
|
||||||
|
;Winbatch_install
|
||||||
|
Shellbatch_install /winst /sysnative
|
||||||
|
|
||||||
|
; include wsusoffline logfile (last 1000 lines)
|
||||||
|
includelog "%Systemroot%\wsusofflineupdate.log" "1000"
|
||||||
|
|
||||||
|
; check exit code, reboot is required
|
||||||
|
Sub_check_exitcode
|
||||||
|
|
||||||
|
[ShellBatch_install]
|
||||||
|
@rem remove old wsusoffline logfile
|
||||||
|
del /q "%Systemroot%\wsusofflineupdate.log"
|
||||||
|
call "%ScriptPath%\client\cmd\DoUpdate.cmd" $Options$
|
||||||
|
exit %ERRORLEVEL%
|
||||||
|
|
||||||
|
[Sub_check_exitcode]
|
||||||
|
comment "Test for installation success via exit code"
|
||||||
|
set $ExitCode$ = getLastExitCode
|
||||||
|
; informations to exit codes see
|
||||||
|
; http://msdn.microsoft.com/en-us/library/aa372835(VS.85).aspx
|
||||||
|
; http://msdn.microsoft.com/en-us/library/aa368542.aspx
|
||||||
|
if ($ExitCode$ = "0")
|
||||||
|
comment "Looks good: setup program gives exitcode zero"
|
||||||
|
else
|
||||||
|
comment "Setup program gives a exitcode unequal zero: " + $ExitCode$
|
||||||
|
if ($ExitCode$ = "1605")
|
||||||
|
comment "ERROR_UNKNOWN_PRODUCT 1605 This action is only valid for products that are currently installed."
|
||||||
|
comment "Uninstall of a not installed product failed - no problem"
|
||||||
|
else
|
||||||
|
if ($ExitCode$ = "1641")
|
||||||
|
comment "looks good: setup program gives exitcode 1641"
|
||||||
|
comment "ERROR_SUCCESS_REBOOT_INITIATED 1641 The installer has initiated a restart. This message is indicative of a success."
|
||||||
|
ExitWindows /Reboot
|
||||||
|
else
|
||||||
|
if ($ExitCode$ = "3010")
|
||||||
|
comment "looks good: setup program gives exitcode 3010"
|
||||||
|
comment "ERROR_SUCCESS_REBOOT_REQUIRED 3010 A restart is required to complete the install. This message is indicative of a success."
|
||||||
|
ExitWindows /Reboot
|
||||||
|
else
|
||||||
|
if ($ExitCode$ = "3011")
|
||||||
|
comment "looks good: setup program gives exitcode 3011"
|
||||||
|
comment "ERROR_SUCCESS: wsusoffline requires reboot and rerun."
|
||||||
|
ExitWindows /ImmediateReboot
|
||||||
|
else
|
||||||
|
logError "Fatal: Setup program gives an unknown exitcode unequal zero: " + $ExitCode$
|
||||||
|
isFatalError
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
27
OPSI/changelog.txt
Normal file
27
OPSI/changelog.txt
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
wsusoffline 20130704.840-9 20130704 Joerg Steffens
|
||||||
|
* bugfix for 64 bit
|
||||||
|
* cleanup
|
||||||
|
|
||||||
|
wsusoffline 20130124.800-8 20130124 Joerg Steffens
|
||||||
|
* uses ShellBatch /sysnative instead of Winbatch. Prevents errors on 64bit?
|
||||||
|
* includelog for native wsusoffline log file (1000 lines)
|
||||||
|
|
||||||
|
wsusoffline 20121008.741-7 20121008 Joerg Steffens
|
||||||
|
* uses wsusoffline 7.4.1 RPM
|
||||||
|
|
||||||
|
wsusoffline 20120127.73-7 20120210 Joerg Steffens
|
||||||
|
* priority: -62, damit die anderen Pakete fuer die es ggf. Updates gibt, vorher installiert werden
|
||||||
|
|
||||||
|
wsusoffline 20120127.73-6 20120205 Joerg Steffens
|
||||||
|
* exit-wrapper
|
||||||
|
* removed instnet35
|
||||||
|
|
||||||
|
wsusoffline 20120127.73-4 20120202 Joerg Steffens
|
||||||
|
* check exit codes and do reboots
|
||||||
|
|
||||||
|
wsusoffline 20120127.73-3 20120131 Joerg Steffens
|
||||||
|
* handle ProductProperties Options
|
||||||
|
|
||||||
|
wsusoffline 20120127.73-2 Joerg Steffens
|
||||||
|
* initial, removed windows media player again, because it requires license check
|
||||||
|
|
31
OPSI/control
Normal file
31
OPSI/control
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
[Package]
|
||||||
|
version: 9
|
||||||
|
depends:
|
||||||
|
incremental: False
|
||||||
|
|
||||||
|
[Product]
|
||||||
|
type: localboot
|
||||||
|
id: wsusoffline
|
||||||
|
name: WSUS offline installer
|
||||||
|
description: installs patches from microsoft
|
||||||
|
advice:
|
||||||
|
version: 20130704.840
|
||||||
|
priority: -62
|
||||||
|
licenseRequired: False
|
||||||
|
productClasses:
|
||||||
|
setupScript: setup.ins
|
||||||
|
uninstallScript:
|
||||||
|
updateScript:
|
||||||
|
alwaysScript:
|
||||||
|
onceScript:
|
||||||
|
customScript:
|
||||||
|
userLoginScript:
|
||||||
|
|
||||||
|
[ProductProperty]
|
||||||
|
type: unicode
|
||||||
|
name: options
|
||||||
|
multivalue: True
|
||||||
|
editable: False
|
||||||
|
description: install options for wsusoffline
|
||||||
|
values: ["/instdotnet4", "/instie8", "/instmsse", "/instpsh", "/instwd", "/nobackup", "/updatecpp", "/updatedx", "/updatercerts", "/updatetsc", "/updatewmp"]
|
||||||
|
|
9
OPSI/postinst
Normal file
9
OPSI/postinst
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
#
|
||||||
|
# postinst script for softprod
|
||||||
|
# This script executes after unpacking files from that archive and registering the product at the server.
|
||||||
|
#
|
||||||
|
# The following environment variables can be used to obtain information about the current installation:
|
||||||
|
# PRODUCT_ID: id of the current product
|
||||||
|
# CLIENT_DATA_DIR: directory which contains the installed client data
|
||||||
|
#
|
9
OPSI/preinst
Normal file
9
OPSI/preinst
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
#
|
||||||
|
# preinst script for softprod
|
||||||
|
# This script executes before that package will be unpacked from its archive file.
|
||||||
|
#
|
||||||
|
# The following environment variables can be used to obtain information about the current installation:
|
||||||
|
# PRODUCT_ID: id of the current product
|
||||||
|
# CLIENT_DATA_DIR: directory where client data will be installed
|
||||||
|
#
|
28
Testing.txt
Normal file
28
Testing.txt
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
*** Qualitiymanagement/Testing procedure
|
||||||
|
|
||||||
|
- Product:
|
||||||
|
- Name: productname
|
||||||
|
- Version: xxx
|
||||||
|
- Release: yyyy
|
||||||
|
|
||||||
|
- Environment
|
||||||
|
- OS: Native windows XP-32Bit installation
|
||||||
|
- Preinstalled packages: None (also no aio)
|
||||||
|
- Files used while testing:
|
||||||
|
File1: http://domain.de/file.ext
|
||||||
|
|
||||||
|
- Testing process:
|
||||||
|
OPSI-action:
|
||||||
|
- Installation (without dependencies like AIO/Firefox): ??
|
||||||
|
Result:
|
||||||
|
- File extensions related to program: ??
|
||||||
|
- Start menu entry: ??
|
||||||
|
- Starting/using program: viewer works, File1 is shown correctly: ??
|
||||||
|
|
||||||
|
OPSI-action:
|
||||||
|
- Uninstall
|
||||||
|
Result:
|
||||||
|
- File extensions related to program: unrelated: ??
|
||||||
|
- Start menu entry: none: ??
|
||||||
|
|
||||||
|
|
22
builder-product.cfg
Normal file
22
builder-product.cfg
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
############################
|
||||||
|
# Setup product information
|
||||||
|
############################
|
||||||
|
VENDOR="wsusoffline.net"
|
||||||
|
PN="microsoft.wsusoffline"
|
||||||
|
NAME="WSUS Offline Update"
|
||||||
|
DESCRIPTION="Update Microsoft Windows and Office without an Internet connection"
|
||||||
|
VERSION="20130723"
|
||||||
|
RELEASE="3"
|
||||||
|
PRIORITY="0"
|
||||||
|
ADVICE=""
|
||||||
|
|
||||||
|
# TYPE - defines, if the install files are public or restricted.
|
||||||
|
# Valid value: restricted | public
|
||||||
|
TYPE="public"
|
||||||
|
|
||||||
|
DL_FILE[0]="wsus.jpg"
|
||||||
|
DL_SOURCE[0]="http://ostermeier.net/wp-content/uploads/2013/06/wsus.jpg"
|
||||||
|
|
||||||
|
# File array index for the image showing while installing the program
|
||||||
|
ICON_DL_INDEX=0
|
||||||
|
|
25
builder-targets-cb.sh
Normal file
25
builder-targets-cb.sh
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
##############################################################################
|
||||||
|
# This optional file "builder-targets-cb.sh" will be called by builder.sh
|
||||||
|
#
|
||||||
|
# The targets will be called from thde opsi-builder using the following
|
||||||
|
# order: config, prepare, retrieve, create, package, publish, commit, cleanup
|
||||||
|
# You can overwrite the target functions in builder-targets-cb.sh
|
||||||
|
#
|
||||||
|
# You can define callback functions. The functions are called from
|
||||||
|
# opsi-builder within processing a target
|
||||||
|
# cb_package_makeproductfile
|
||||||
|
#
|
||||||
|
# You can use every variable defined in any configuration file or by
|
||||||
|
# the defined builder script itself. Also, calling the predefined
|
||||||
|
# targets builder_<targetname> is possible.
|
||||||
|
#
|
||||||
|
# Abstract:
|
||||||
|
# target order: config, prepare, retrieve, create, package, publish, commit, cleanup
|
||||||
|
# callbacks: <none>
|
||||||
|
#
|
||||||
|
##############################################################################
|
||||||
|
|
||||||
|
function cleanup() {
|
||||||
|
echo "Cleanup"
|
||||||
|
builder_cleanup
|
||||||
|
}
|
1
wsus.jpg.sha1sum
Normal file
1
wsus.jpg.sha1sum
Normal file
@ -0,0 +1 @@
|
|||||||
|
e28ec16c3a6a7c3e7df14c402e8a52fc1982cc8a /home/mario/.opsi-dist-cache/microsoft.wsusoffline-20130723//wsus.jpg
|
Loading…
Reference in New Issue
Block a user