Skip to content

Agent not selectable under environments in subgroup's projects when shared with parent group

If a general gitlab-agent for a group is made and group ids are used in .gitlab/agents/<gitlab-agent>/config.yaml the agent is not selectable for an environment under a subgroup repository:

user_access:
  access_as:
    agent: {}
  groups:
    - id: cluster

my groups structure:

  • Cluster --> (Gitlab-agent is placed here)
    • Applications
      • Hello-world
    • Infrastructure
      • EKS-IaC
      • Cluster-Management --> (Gitlab-agent needs to be selected here for the Kubernetes Dashboard)

If dedicated gitlab-agent is placed under cluster/infrastructure/cluster-management then the agent can be selected under the environments.

Another workaround is adding the immediate parent group id to the list:

user_access:
  access_as:
    agent: {}
  groups:
    - id: cluster
    - id: infrastructure
Edited by Priyan Sureshbabu