Move the CI Tunnel for GitLab Kubernetes Agent to Core
## Release notes
Connecting a Kubernetes cluster with GitLab simplifies the necessary setup for deployments and using the GitLab Kubernetes Agent enables GitOps style deployments to the cluster. Initially, the GitLab Kubernetes Agent was available only for Premium customers. We are happy to move the core features of the GitLab Kubernetes Agent to GitLab Core in alignment with our open source ethos. We expect that the open sourced features are compelling to many users without dedicated infrastructure teams and strong requirements around permissions management. Advanced permissions management features are made available as part of the GitLab Premium offering.
https://docs.gitlab.com/ee/user/clusters/agent/
## Moved to ~"GitLab Core"
We are connecting the GitLab CI/CD with an in-cluster agent, and enable CI jobs to target kubernetes clusters through an agent using the [CI tunnel](https://gitlab.com/groups/gitlab-org/-/epics/5528). The [first iteration of the CI tunnel](https://gitlab.com/groups/gitlab-org/-/epics/5781) is expected to be released in %"14.1". This feature enables users to run commands against their cluster using the agent's service account, and is being moved to Core.
Together with this change, the agent registration logic is being moved to Core too.
Moreover, we plan to deliver [the group-level extension](https://gitlab.com/groups/gitlab-org/-/epics/5784) of the CI tunnel - reusing the agent's service account - in gitlab~13116818 too in a future milestone.
This decision was made in the https://gitlab.com/gitlab-com/Product/-/issues/2690#note_617899861 (internal) issue. The timeline is to deliver it as soon as we can, likely in %"14.2" or %"14.3".
## Other features
The Agent today supports
- pull based deployments
- network security policy integrations
- ... (other features we are working on, planning)
These features are not being moved to gitlab~13116818 and such a move is not planned at this moment. If you are interested in these features being moved, please, add your comment, possibly with a detailed use case description.
## Definition of done
- [ ] Relocate all Agent code into Core directories
- [ ] Ensure thorough testing is done manually and that automated tests are updated
- [ ] Determining premium features and isolate them
- [ ] Enforce licensing requirements in internal API
- [ ] Update Documentation
epic