Bug description
Running helm install --create-namespace as a Capsule tenant owner fails with a 403 Forbidden on namespace-scoped resources, even though the tenant owner has cluster-admin as their clusterRole.
Creating the namespace with kubectl works fine.
How to reproduce
Steps to reproduce the behavior:
- Provide the Capsule Tenant YAML definitions
`apiVersion: capsule.clastix.io/v1beta2
kind: Tenant
metadata:
name: my-tenant
spec:
owners:
- kind: Group
name: my-tenant
clusterRoles:
- cluster-admin
- capsule-namespace-deleter
forceTenantPrefix: true`
- Run as a tenant owner
helm upgrade --install my-release ./my-chart \ --namespace my-tenant-test \ --create-namespace
Expected behavior
Helm creates the namespace and installs the chart successfully.
Logs
Error: Unable to continue with install: could not get information about the resource ServiceAccount "my-release-sa" in namespace "my-tenant-test": serviceaccounts "my-release-sa" is forbidden: User "..." cannot get resource "serviceaccounts" in API group "" in the namespace "my-tenant-test"
If applicable, please provide logs of capsule.
In a standard stand-alone installation of Capsule,
you'd get this by running kubectl -n capsule-system logs deploy/capsule-controller-manager.
Additional context
- Capsule version: 0.12.4
- Helm version: v3.19.0
- Kubernetes version: EKS 1.31
Bug description
Running helm install --create-namespace as a Capsule tenant owner fails with a 403 Forbidden on namespace-scoped resources, even though the tenant owner has cluster-admin as their clusterRole.
Creating the namespace with kubectl works fine.
How to reproduce
Steps to reproduce the behavior:
`apiVersion: capsule.clastix.io/v1beta2
kind: Tenant
metadata:
name: my-tenant
spec:
owners:
name: my-tenant
clusterRoles:
forceTenantPrefix: true`
helm upgrade --install my-release ./my-chart \ --namespace my-tenant-test \ --create-namespaceExpected behavior
Helm creates the namespace and installs the chart successfully.
Logs
Error: Unable to continue with install: could not get information about the resource ServiceAccount "my-release-sa" in namespace "my-tenant-test": serviceaccounts "my-release-sa" is forbidden: User "..." cannot get resource "serviceaccounts" in API group "" in the namespace "my-tenant-test"If applicable, please provide logs of
capsule.In a standard stand-alone installation of Capsule,
you'd get this by running
kubectl -n capsule-system logs deploy/capsule-controller-manager.Additional context