Skip to content

muhammadhassaan-solves/secure-access-in-k8s-with-serviceaccounts-and-rbac

Repository files navigation

Secure Access in Kubernetes with ServiceAccounts and RBAC

Description

This lab demonstrates how to implement secure access control in Kubernetes using ServiceAccounts and Role-Based Access Control (RBAC). I created custom ServiceAccounts, assigned them limited permissions using both Roles and ClusterRoles, and linked them using RoleBindings and ClusterRoleBindings. The access was tested to verify both namespace-level and cluster-wide permissions.

Tools and Technologies

  • Kubernetes
  • RBAC
  • ServiceAccounts
  • YAML

Project Walk-through

Create ServiceAccount


Define Role


Create a RoleBinding to bind the Role to the ServiceAccount


Deploy Test Apps using ServiceAccounts


Test RBAC


Create a ClusterRole for Cluster-Wide Access & Test ClusterRole permissions


Create a minimal-permission ServiceAccount & Audit all RBAC configurations


About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages