Installing & Updating Packages

Security Requirements and Controls

Packages are available in the online Package Marketplace and as standalone files, either shared as a Zip file or through a repository such as Github.

There are three methods available for managing packages:

If you decide to use the User Interface, you will be able to merge local changes with changes made in the new version of the package.

Install a Package via UI

To install a package from the LogScale Marketplace:

  1. Go to the Marketplace under the Settings tab in your view.

  2. Choose a package from the list in the package summary.

  3. Choose the version of the package you want to install. The default version will be the latest version available, but you can select to install an earlier version if you wish.

  4. Click the Install package button.

  5. You will be presented with a summary of the components that will be installed.

    Installing Packages UI

    Figure 63. Installing Packages UI


  6. Click the Install button to install the package. Click the Cancel button to return to the package summary.

  7. Once the package has been installed, you will be taken to the Installed package list

Once you have installed a package, it will appear under the PackagesInstalled section of the Settings tab.

If you installed a library, you will now be able to navigate to dashboards , saved queries, alerts and parsers and from there create a new component based on a template from that library.

If you installed an application you will also be able to create new components based on the components within the application in the same way as when you install a library.

When using a component, you will find a grouping in the lists of components with the name of the application and under that you will find these managed components. Application components are freely customizable, including deleting parts not required. However, care should be taken as deleting components may implications when Update Packages via UI as updating an application will re-install deleted components.

Update Packages via UI

To update a package through the UI:

  1. Go to the Packages section under the Settings tab in your repository or view.

  2. You can either go to:

    • Marketplace. If a package update is available, an Update Available note will be shown next to the installed package in the list of available packages.

    • Installed packages.

  3. Selec the package to show the Package summary; you will see a Update to this version button. You can update a different version and not just the latest version available.

  4. You will be presented with an update dialog that lists the components that will be updated or changed with this update.

    Updating Packages UI

    Figure 64. Updating Packages UI


  5. To update click Update, this will take you through the update process. Once the update has been completed you will be sent to the Installed section of the Packages view.

In the case of libraries, the component templates from the package are updated. Templates that have been modified from the original package remain unchanged.

For applications, where component templates are materialized during installation and afterwards managed by LogScale, you may encounter conflicts during the upgrade process. Conflicts arise when you have made local changes to an application component prior to updating it. For example, if you installed an application with a dashboard and you've changed a widget of that dashboard , a conflict may occur when you update that application. In order to resolve conflict while updating an application LogScale supports a basic Use Ours/Theirs merging view that lets you choose what to do with each conflicting component, meaning you either keep the modified version or replace it completely with the new version.

If you are using the LogScale CLI you are able to entirely overwrite the installed package without handling update conflicts.

Uninstall a Package via UI

If you want to uninstall a package you can do so through the UI or the CLI. Doing so will remove the components and templates previously installed by the package, even those that might currently be in use on your system.

To uninstall a package through the UI

  1. Go to the Marketplace under the Settings tab in your view

  2. Go to Installed packages list under the Settings tab

  3. Choose the package you want to Uninstall

  4. Click the Uninstall button

  5. You will be prompted that uninstalling the package will remove all components, including those you are currently using from your system. You will need to enter the full name of the package to confirm deletion.

Install a Package from a File

To install a package from a Zip file that you have downloaded:

  1. Go to the Marketplace under the Settings tab in your view

  2. Go to Installed packages list under the Settings tab

  3. Click the Upload button.

  4. You can either drag and drop a package from your machine, or use the file selector to navigate and choose a package Zip file from your local machine.

  5. You will be presented with a summary of the components that will be installed when the package has been added to your system.

  6. Click the Install button to install the package. Click the Cancel button to return to the package summary.

  7. Once the package has been installed, you will be taken to the Installed package list

Once you have installed a package, it will appear under the PackagesInstalled section of the Settings tab.

Update a Package from a File

To update an existing package from a file:

  1. Go to the Marketplace under the Settings tab in your view

  2. Go to Installed packages list under the Settings tab

  3. Click the Upload button.

  4. You can either drag and drop a package from your machine, or use the file selector to navigate and choose a package Zip file from your local machine.

  5. You will be presented with an update dialog that will list the components that will be updated or changed with this update.

  6. To update click Update, this will take you through the update process.

Once the update has been completed you will be sent to the Installed section of the Packages view.

Install a Package in CLI with humioctl

Installing packages this way will override any manual modification made in the UI. This is equivalent to a force push in git terminology. Any changes must be exported and placed in source control.

Let's install the package we just exported and unzipped:

logscale
humioctl packages install /path/to/my/packages/root/

Alternatively, if you're maintaining your package on Github you can install from the Github URL,

logscale
humioctl packages install https://github.com/myorg/my-package/

Or you can point directly to the zip file you just created:

logscale
humioctl packages install /path/to/my/package.zip

For additional options, use humioctl packages install --help

Uninstall a Package using the CLI

To uninstall a package using the CLI, you must quote the package name:

logscale
humioctl packages uninstall github/events

Install a Package from a Zip File using GraphQL

You can install a previously downloaded package directly into LogScale using the installPackageFromZip() GraphQL mutation.

To do this, you must specify the name of the file on the command-line using curl you will need to specify a multi-part form entry, one part consisting of the mutation and the other the name of the file of the package to bee installed. For example:

shell
$ curl --location 'https://$YOUR_LOGSCALE_URL/graphql' \
--header 'Authorization: Bearer XXXXXXXXXXXXXX\
--header 'accept: application/json, multipart/mixed' \
--form 'file=@"package.zip"' \
--form 'json="{\"query\":\"mutation {installPackageFromZip(viewName: \\\"Package_Testing\\\",overwrite: true) {wasSuccessful}}\"}";type=application/json'

When completed successfully you will get the success message back:

json
{
  "data": {
    "installPackageFromZip": {
      "wasSuccessful": true
    }
  }
}