Skip to content

This repository wraps the KustoSchemaTools into a CLI tool inside a container. This way it can be used as GitHub Action

License

Notifications You must be signed in to change notification settings

github/KustoSchemaToolsAction

Repository files navigation

KustoSchemaToolsAction

This tool can be used to synchronized your schema from Azure Data Explorer (Kusto) cluster to yml files in a GitHub repository and back, using GitHub Actions.

Getting Started

  1. Create a repository for versioning your files
  2. Copy the actions.yaml file from the workflows folder to your repository in the folder .github/actions/KustoSchemaTools
  3. Copy the workflows that you want (import, diff, apply) from the workflows folder to your repository in the folder .github/workflows
  4. The workflows use OIDC to login to Azure. You can use a service principal instead. Make sure, that the identity you use has access to your Azure Data Explorer (Kusto) cluster
  5. Create a folder for your cluster/deployment and add a clusters file.
  6. Import the databases you want to synchronize
  7. Make changes to the yaml files and create a PR
  8. The diffs will be posted as PR comment
  9. Merge the PR to roll out the changes to your Azure Data Explorer (Kusto) cluster

This project can be used as it is and doesn't require customizations. In the repo

Adding custom behavior

KustoSchemaTools uses plugins for reading the and writing the schema from or to a database or yaml file. You can find more docs on that in the KustoSchemaTools repo.

The easiest way to add your own logic is to

  1. Fork this repository
  2. Implement your own plugins (examle)
  3. Register them in the Program.cs
  4. Build your own docker container (workflow)
  5. Add the definition of your action if required.
  6. Use the provided workflows with your container (import, diff, apply)

About

This repository wraps the KustoSchemaTools into a CLI tool inside a container. This way it can be used as GitHub Action

Topics

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published