Search Results for

    Show / Hide Table of Contents

    Create a Bundle Package

    Up to this point we have been creating separate packages for the components needed to run a LS Central POS with customizations. Now we would like to combine these packages into one setup, which is where a bundle package comes in. A bundle package should not install anything, but only have dependencies to the packages we want to include in a single installation and maybe pre-set any parameters to simplify the setup.

    Lets take a look at an example:

    $ErrorActionPreference = 'stop'
    
    Import-Module UpdateServiceServer
    
    $SetupBundle = @{
        Id = "bundle/my-pos"
        Version = '1.0'
        Name = "My POS"
        Instance = $true
        Dependencies = @(
            @{Id = "sql-server-express"; Version = "-"}
            # The database package must be placed before bc-server package or his depentant.
            @{ Id = "my-database"; Version = '1.0' } 
            @{ Id = "my-dotnet-server-addin"; Version = ">=1.0" } 
            # Skip this package if you do not want the Windows Client:
            @{ Id = "my-dotnet-client-addin"; Version = ">=1.0" } 
            @{ Id = "my-objects"; Version = '1.0' }
            @{ Id = "my"; Version = '1.0' }
            # We always want the newest license:
            @{Id = "my-license"; Version = '!^' }
            @{Id = "ls-central-toolbox-server"; Version = ''}
            @{Id = "ls-central-toolbox-client"; Version = ''}
            # Skip this package if you do not want the Web Client
            @{ Id = "bc-web-client"; Version = '14.0' }
        )
        OutputDir = $OutputDir
    }
    
    New-UssPackage @SetupBundle | Import-UssPackage
    

    This example creates a new package called bundle/my-app-pos where we have listed dependencies to packages we want to include on our POS installation.

    Under the dependency section we have listed the packages

    Now lets break it down:

    1. First we use the cmdlet New-UssPackage to create a new package, this package doesn't really install anything, except its dependencies, where we have picked packages we want to include in this setup.
    2. Next we create a new setup bundle with New-UssInstaller where we determine the name of the subscription and give it a unique identifier.
    3. Then, we attach the package to the setup bundle with Set-UssInstallerPackage.
      • Version: This can be a specific version or a version range.
      • UpdateStrategy: You can specify if it should update automatically (Automatic) or manually (Manual)
      • InstanceNameSuggestion: You can specify the default instance name - can be overwritten at install time.
    4. And last, we create an installer for the setup bundle with Get-UssInstaller.
      • Note: The installer only has a reference to the setup bundle, if you change the packages or their version in the bundle, the installer changes accordingly.
    In This Article
    Back to top Generated by DocFX