Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

Introduction

Packages in CapaInstaller have always been built on VBScript, but since the PowerShell scripting language is taking over the way most IT professionals manage task automation, it is now possible to build packages in CapaInstaller, using PowerShell.

Creating a PowerPack

Creating a PowerPack is straight forward, as it starts by right-clicking Application and Packages in the root point of your installation and then clicking on Create PowerPack…

Fill in the Package Name and optionally set a Package Version and a Description. The Display name automatically follows a concatenation of name and version. You can edit the Display Name manually if you want to. When you’re done, click Create.

The newly created PowerPack is then created, and is visible inside the CI Console. In the same way that CapaPacks differ from native packs by the blue color, PowerPacks are shown with a green package icon.

Setting an Editor for PowerShell

When editing PowerShell scripts, you can use a different editor than you would normally use for other (.vbs) scripts. To set it up, click Tools => Options…

-and select the General Tab on the left side.

The Native Integrated Scripting Editor (ise) for PowerShell is powershell_ise.exe. The full path is; %SystemRoot%\system32\WindowsPowerShell\v1.0\powershell_ise.exe.

Editing scripts

When editing installation scripts for VBScript based packages, the default editor is launched with the full path of the script, which is located inside the Package in the Scripts folder., like this;

For PowerPacks, however, the installation scripts are located in the SQL database (in the JOB table), and when you Right click on a PowerPack and then select ‘Edit installation script’, the script is saved in a temporary folder, and the PowerPack Editor is then launched with the temporary script.

The Ci Console will monitor the file, at track any changes when you save them. To make sure that the changes made were deliberate, the Change log dialog is shown to let you add a reason for the edit.

When you click Ok, the script is saved to the database.

Having the installation scrips in the database offers the ability to edit the scripts and install the package without starting an ‘Update Now’ synchronization action to other containers.

How it works

  • No labels