5.0

Importing

The CLI allows you to import resources from files in Lenses into another environment.

Import is done on a per resource basis, the directory structure defined by the cli whereas a base directory can be provided by the —dir flag.

Processors, connectors, topics and schemas have an additional prefix flag to restrict resources to export.

lenses-cli import acls --dir my-dir
lenses-cli import alert-channels --dir my-dir
lenses-cli import alert-settings --dir my-dir
lenses-cli import audit-settings --dir my-dir
lenses-cli import connections --dir my-dir
lenses-cli import connectors --dir my-dir
lenses-cli import processors --dir my-dir
lenses-cli import quotas --dir my-dir
lenses-cli import schemas --dir my-dir
lenses-cli import topics --dir my-dir
lenses-cli import policies --dir my-dir
lenses-cli import groups --dir my-dir
lenses-cli import serviceaccounts --dir my-dir

The directory structure is as follows:

my-dir
├── alert-settings
│   └── alert-setting.yaml
├── apps
│   ├── connectors
│   │   ├── connector-1.yaml
│   │   └── connector-2.yaml
│   └── sql
├── audit-channels
|   └── audit-channel-channel-1.yaml
├── groups
│   └── groups.yaml
├── kafka
│   ├── quotas
│   │   └── quotas.yaml
│   └── topics
│       ├── topic-1.yaml
│       └── topic-2.yaml
├── policies
│   └── policies-city.yaml
├── service-accounts
│   └── servic-eaccounts.yaml
└── schemas
    ├── schema-1.yaml
    └── schema-2.yaml