An error occurred while fetching the assigned iteration of the selected issue.
Have ability to rollout agent-kas per project on GitLab.com
As part of the production rollout, we can consider enabling the agent for a test project on GitLab.com, before enabling for all GitLab.com.
Proposal
Add GitLab.com specific feature flag to enable project-based allowlist for
- creation of agent
- authentication of agent in internal Kubernetes API
old idea
FF Check in internal API
It will require a small product change, that will look something like:
diff --git a/lib/api/internal/kubernetes.rb b/lib/api/internal/kubernetes.rb
index d4690709de4..34b95be8daf 100644
--- a/lib/api/internal/kubernetes.rb
+++ b/lib/api/internal/kubernetes.rb
@@ -52,6 +52,10 @@ def check_feature_enabled
def check_agent_token
forbidden! unless agent_token
+
+ if Gitlab.com?
+ not_found! unless Feature.enabled?(:kubernetes_agent_rollout, agent.project)
+ end
end
end