zkayyali812 / acm-generic-import-demo

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

acm-generic-import-demo

Goal of the PoC and demo

this demo will iterate through all the kubeconfig and demonstrate that you can use a generic kubeconfig to import multiple clusters

Structure of the project

├── approve-import.sh
├── az-get-kubeconfig.sh
├── configs
│   ├── bootstrap-kubeconfig.yaml
│   └── dockerconfig.json.b64
├── demo
├── demo-cleanup.sh
├── demo-magic
├── generic-import-hub-cleanup.sh
├── generic-import-hub-setup.sh
├── generic-import.sh
├── kubeconfigs
│   ├── kubeconfig-1
│   ├── kubeconfig-1
│   └── kubeconfig-...
└── templates
    ├── bootstrap-kubeconfig.yaml
    ├── crds.yaml
    ├── import.yaml
    └── managedcluster.yaml
  • demo: run the main demo
  • demo-magic: magic that drives the demo
  • demo-cleanup.sh: cleanup after demo
  • generic-import-hub-setup.sh: setup script to run against hub before demo.
  • generic-import-hub-cleanup.sh: cleanup script for after the demo.
  • generate-import.sh: heart of this demo to execute the import flow.
  • approve-import.sh: script for SRE to approve ManagedCluster join to the hub.
  • az-get-kubeconfig.sh: helper script to get AKS kubeconfig from Azure.
  • configs: directory containing stuff generated by setup script.
  • templates: directory containing templates use by setup and import scripts.
  • kubeconfigs: directory containing the kubeconfigs for the managedcluster

Setting up the demo

Before running demo script run generic-import-hub-setup.sh against the hub generic-import-hub-setup.sh perform the following setup:

  • create generic-import namespace
  • setup generic-import serviceaccount with permission
  • generate configs/bootstrap-kubeconfig.yaml
  • (optional) extract image pull-secret from hub

Place kubeconfig files in the kubeconfigs directory, kubeconfig file name will be use for the ManagedCluster name

Running the demo

./demo

Cleanup the demo

./demo-cleanup.sh ./generic-import-hub-cleanup.sh

About

License:Apache License 2.0


Languages

Language:Shell 100.0%