Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for exporting and importing all entities #2515

Open
jensalm opened this issue Nov 1, 2024 · 5 comments · May be fixed by #2571
Open

Add support for exporting and importing all entities #2515

jensalm opened this issue Nov 1, 2024 · 5 comments · May be fixed by #2571
Assignees
Labels
enhancement New feature or request

Comments

@jensalm
Copy link

jensalm commented Nov 1, 2024

Allow the cli to export and import all entities. The export should not contain instance specific details like ids, when it was created, etc.
The output from export should be able to be imported in an empty ziti instance.
Output should support both json and yaml.

Example:

  "identities": [
    {
      "appData": {},
      "authPolicy": "@Default",
      "disabled": false,
      "externalId": null,
      "isAdmin": true,
      "isDefaultAdmin": false,
      "isMfaEnabled": false,
      "name": "Test 1",
      "roleAttributes": [],
      "tags": {},
      "typeId": "Default"
    }
  ],
  "configs": [
    {
      "data": {
        "addresses": [
          "google.ziti"
        ],
        "portRanges": [
          {
            "high": 120,
            "low": 80
          }
        ],
        "protocols": [
          "tcp"
        ]
      },
      "name": "test 1 intercepting config",
      "tags": {},
    }
  ]
  "services": [
    {
      "configs": [
        "@test 1 intercepting config"
      ],
      "encryptionRequired": true,
      "name": "test 1",
      "roleAttributes": [
        "services"
      ],
      "tags": {},
      "terminatorStrategy": "smartrouting"
    }
  ]
@jensalm jensalm self-assigned this Nov 1, 2024
@jensalm jensalm changed the title Add support for importing and export all entities to recreate a ziti instance Add support for importing and exporting all entities to recreate a ziti instance Nov 1, 2024
@jensalm jensalm changed the title Add support for importing and exporting all entities to recreate a ziti instance Add support for exporting and importing all entities to recreate a ziti instance Nov 1, 2024
@dovholuknf dovholuknf added the enhancement New feature or request label Nov 1, 2024
@qrkourier
Copy link
Member

qrkourier commented Nov 1, 2024

What's an example use case for the feature? By recreate do you mean clone to a fresh network as opposed to managing a Ziti network's entities?

@jensalm jensalm changed the title Add support for exporting and importing all entities to recreate a ziti instance Add support for exporting and importing all entities Nov 1, 2024
@jensalm
Copy link
Author

jensalm commented Nov 1, 2024

What's an example use case for the feature? By recreate do you mean clone to a fresh network as opposed to managing a Ziti network's entities?

Basic use case is to be able to "clone" a network.

@mvarchdev
Copy link

Also I was looking for this. It would be nice not only to export/import entities but also policies and basically configuration at its whole. Lets say I have dev team that want to replicate env, or I have application and I want to store roles/policies per-app/per-service and just sync it from git...

@dovholuknf
Copy link
Member

Hi @mvarchdev - that's exactly what @jensalm PR will do/does. see: #2571

@dovholuknf dovholuknf linked a pull request Jan 6, 2025 that will close this issue
@qrkourier
Copy link
Member

Let's distinguish between cloning (import/export) and configuration management. The forthcoming tool has import/export, but not configuration management.

The difference is one-shot import vs. as-code management, e.g., gitops. Configuration management usually means you express the desired state in some file, probably under version control, and the config system reconciles that desired state with the actual state. For that, you'd probably use Kubernets CRDs, Ansible, Terraform, Pulumi, Salt Stack, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants