Uploaded image for project: 'OpenShift GitOps'
  1. OpenShift GitOps
  2. GITOPS-5640

Cluster-scoped Rollouts installs should be restricted to user-defined namespace

XMLWordPrintable

    • 8
    • False
    • None
    • False
    • GitOps Scarlet - Sprint 3263, GitOps Scarlet - Sprint 3264, GitOps Scarlet - Sprint 6/3265

      In order to avoid the potential for privilege escalation, cluster administrators (responsible for installing the operator) should specifically identify the namespaces that cluster-scoped Argo Rollouts can be installed to.

      The set of valid namespaces for cluster-scoped Argo Rollouts installs is specified (as a comma-separated list) via the CLUSTER_SCOPED_ARGO_ROLLOUTS_NAMESPACES environment variable of the operator.

      This allows administrators to ensure that only authorized users have access to those namespaces.

      A cluster-scoped Argo Rollouts install – by virtue of having the requirement of writing to objects across all the cluster-namespaces – requires a powerful ClusterRole/Binding. It is thus beneficial to set guard rails on who can access the namespace associated with that install.

       

      See https://docs.google.com/document/d/1ad-4aH7B1fJi7WEEKSzXNpHiz8sebfLCnpaZRhWqIoQ/edit and https://redhat-internal.slack.com/archives/C01RQH8KQ87/p1726093952356569 for implementation details.

      Acceptance Criteria (Mandatory)

      • New env var 'CLUSTER_SCOPED_ARGO_ROLLOUTS_NAMESPACES': Argo Rollouts will only allow installs of cluster-scoped rollouts into these namespaces (will only reconcile RolloutManagers in these namespace, otherwise an error will be set on .status.conditions).
      • Cluster-scoped Rollouts can be installed into 'openshift-gitops' by default, but only if 'CLUSTER_SCOPED_ARGO_ROLLOUTS_NAMESPACES' is empty.
      • See linked google doc for details.
      • We will need to backport this to 1.13 and 1.14
      • Doc updates required:
        • We will need to ensure this is documented as a breaking change in 1.13/1.14 docs.
        • The example RolloutManager CR on this page should be installed into openshift-gitops namespace. That is, .metadata.namespace should be 'openshift-gitops'
        • We should find a spot in the Rollout docs to document the 'CLUSTER_SCOPED_ARGO_ROLLOUTS_NAMESPACES' env var, and how it can be used to install cluster-scoped Argo Rollouts to different namespaces.
      • Unit/E2E tests

              jparsai Jayendra Parsai
              jgwest Jonathan West
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: