Hello @Rachana K P
Namespaces is forbidden. User cannot create resource "namespaces" in API group " at the cluster scope: User does not have access to the resource in Azure. Update role assignment to allow access
The error message indicates that the user account you are using does not have the necessary permissions to create namespaces in the Kubernetes cluster.
To resolve this issue, you will need to update the role assignment for the user account to allow access to the necessary resources. You can do this by following these steps:
- Open the Azure portal and navigate to the Kubernetes cluster that you are working with.
- Click on "Access control (IAM)" in the left-hand menu.
- Click on the "Add" button at the top of the page to add a new role assignment.
- In the "Add role assignment" pane, select the appropriate role that grants the necessary permissions to create namespaces. For example, you could select the "Kubernetes Cluster Administrator" role.
- In the "Assign access to" section, select "User, group, or service principal".
- In the "Select" field, enter the name of the user account that you are using.
- Click on the "Save" button to save the new role assignment.
Once you have updated the role assignment, you should be able to create namespaces in the Kubernetes cluster without encountering an error message.
Please accept answer and upvote if the above information is helpful for the benefit of the community.