Skip to content

Delete a Package

This page provides instructions on how to delete a package in kdb Insights Enterprise using the CLI.

Using the web interface or the CLI

kdb Insights Enterprise has both a web interface and command line interface (CLI). For information on how to delete packages using the web interface, refer to the web interface documentation.

Remove a package

Once you are finished using a package in kdb Insights Enterprise, you can remove it. You can use the help command to provide information regarding the additional options, as follows:

kxi pm rm --help
 Usage: kxi pm rm [OPTIONS] ID [VERSION]                                        

 Remove   a package from kdb+ Insights Enterprise Package Manager service.      
 ID: package-name or package-uuid (supports glob patterns)                      

╭─ Authentication option overrides ────────────────────────────────────────────╮
│ --hostname,--url                TEXT  Insights URL                           │
│                                       [env: INSIGHTS_URL]                    │
│ --realm                         TEXT  Realm                                  │
│                                       [env: INSIGHTS_REALM]                  │
│ --client-id                     TEXT  Client id                              │
│                                       [env: INSIGHTS_CLIENT_ID]              │
│ --client-secret                 TEXT  Client secret                          │
│                                       [env: INSIGHTS_CLIENT_SECRET]          │
│ --auth-enabled/--auth-disabled        Retrieve Bearer Token                  │
│                                       [env: KXI_AUTH_ENABLED]                │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --teardown                            Teardown the package before removing.  │
│ --rm-data                             Remove the data associated with the    │
│                                       deployment                             │
│ --output-format     -o  [json|table]  Output format for the command.         │
│                                       default: 'table'.                      │
│ --server-timeout        INTEGER       Timeout for Insights server calls      │
│                                       [env: INSIGHTS_SERVER_TIMEOUT]         │
│ --yes,--assume-yes  -y                Automatic yes to prompts; assume "yes" │
│                                       as answer to all prompts and run       │
│                                       non-interactively.                     │
│ --help                                Show this message and exit.            │
╰──────────────────────────────────────────────────────────────────────────────╯

Removing a package from kdb Insights Enterprise can be done as follows:

kxi pm rm test-package

Rm with 'test-package' and version=None
╭──────────────┬─────────┬────────────────────────────────┬──────────────────────────────────────╮
│ name          version  owner.name                      id                                   │
├──────────────┼─────────┼────────────────────────────────┼──────────────────────────────────────┤
│ test-package  0.0.1    service-account-test-publisher  add333ad-bdd2-41a9-bcc7-a24fdbee598f │
╰──────────────┴─────────┴────────────────────────────────┴──────────────────────────────────────╯

Delete local packages and files

The CLI no longer maintains a registry of locally installed packages, and the kxi package install and kxi package uninstall commands are no longer available.

To remove a package from kdb Insights Enterprise, use kxi pm rm <package> as described in Remove a package.

To discard a local package working directory or a generated .kxi package file, delete that file or directory using the normal filesystem tools for your environment.

Next steps

Back to top