Attach existing cluster using kubectl (plugin)

Problem to solve

As a Platform Operator, I want to use known, CLI oriented tools to attach a cluster, so that I feel familiar with the process.

The documented process to add an existing cluster is more involved than it needs to be. Given a KUBECONFIG, a GITLAB_TOKEN, and a project/group/instance selection, the rest can be automated.

@hfyngvason put together this kubectl plugin to demonstrate. With this plugin, one can run

kubectl gitlab --project $project add

Intended users

User experience goal

Allow the user to import existing clusters under GitLab using kubectl

Proposal

To make the initial prototype production ready we need

  • it should be moved under gitlab-org/cluster-integration
  • it needs CI/CD with tests and a build matrix for popular operating systems and architectures, e.g. (macos,linux,windows)x(amd64,arm64)
  • it should collect usage data

Further details

Permissions and Security

Documentation

Availability & Testing

What does success look like, and how can we measure that?

What is the type of buyer?

Is this a cross-stage feature?

Links / references

Edited by Viktor Nagy (GitLab)