📚Book Signing at KubeCon EU 2026Meet us at Booking.com HQ (Mon 18:30-21:00) & vCluster booth #521 (Tue 24 Mar, 12:30-1:30pm) — free book giveaway!RSVP Booking.com Event

🔐 Security Recipes

Secure your Kubernetes clusters with RBAC, Secrets management, Pod Security Standards, service accounts, and security best practices.

48 recipes available

Intermediate

Quay Default Permissions for Robot Accounts

Configure organizational default permissions in Quay Registry to automatically grant read access to robot accounts on every new repository. LDAP and team patterns.

⏱ 15 minutes K8s 1.28+

Add Custom CA Certificates in OpenShift

Configure custom Certificate Authority trust across an OpenShift cluster using proxy config, image config, and automatic CA bundle injection into pods.

⏱ 20 minutes K8s 1.25+

Add Custom CA in OpenShift and Kubernetes

Configure custom Certificate Authority trust in both OpenShift and vanilla Kubernetes for private registries, internal services, and corporate PKI.

⏱ 25 minutes K8s 1.25+

Add Custom CA Certificates in Kubernetes

Configure custom Certificate Authority trust in vanilla Kubernetes using ConfigMap mounts, node-level trust stores, and containerd registry configuration.

⏱ 20 minutes K8s 1.25+

GPU Tenant Bootstrap Bundle

Provision GPU tenants with a single Kustomize bundle containing namespace, RBAC, NetworkPolicy, quotas, and HAProxy VIP config.

⏱ 15 minutes K8s 1.28+

Multi-Tenant GPU Namespace Isolation

Isolate GPU workloads across tenants using namespaces, RBAC, NetworkPolicy, and ResourceQuotas on OpenShift and Kubernetes.

⏱ 15 minutes K8s 1.28+

NetworkPolicy Deny-Default for GPU Tenants

Implement deny-by-default NetworkPolicy for GPU tenant namespaces with NCCL port exceptions and DNS egress on Kubernetes.

⏱ 15 minutes K8s 1.28+

Network Policies for OpenClaw on Kubernetes

Secure OpenClaw deployments with Kubernetes NetworkPolicies to restrict egress to messaging APIs, block unauthorized ingress, and isolate the gateway.

⏱ 15 minutes K8s 1.28+

Secure Secrets Management for OpenClaw on Kubernetes

Manage API keys, bot tokens, and credentials for OpenClaw on Kubernetes using Kubernetes Secrets, External Secrets Operator, and Sealed Secrets.

⏱ 20 minutes K8s 1.28+

Filter CatalogSource Operators by Package

Curate a minimal CatalogSource with only approved operators using opm index pruning and file-based catalog filtering for security and compliance.

⏱ 25 minutes K8s 1.26+

OpenShift Cluster-Wide Pull Secret with Robot Account

Replace admin credentials in the OpenShift cluster-wide pull secret with a Quay robot account for secure, auditable container image pulls across all namespaces.

⏱ 20 minutes K8s OCP 4.x

OpenShift Custom CA for Private Registries

Configure OpenShift to trust a custom Certificate Authority for private container registries using additionalTrustedCA and image.config.openshift.io settings.

⏱ 15 minutes K8s OCP 4.x

RHACS Compliance Scanning

Run CIS, NIST, PCI DSS, and HIPAA compliance scans with Red Hat Advanced Cluster Security and automate reporting for audits.

⏱ 15 minutes K8s 1.28+

RHACS CI/CD Pipeline Integration

Integrate Red Hat Advanced Cluster Security into CI/CD pipelines with roxctl for image scanning, policy checks, and deployment validation.

⏱ 15 minutes K8s 1.28+

Rotate Quay Robot Tokens in Kubernetes

Automate Quay robot account token rotation across Kubernetes namespaces with zero-downtime credential updates and validation scripts.

⏱ 15 minutes K8s 1.24+

SELinux and SCC Config for GPU Operator

Understand SELinux device relabeling and Security Context Constraints (SCC) requirements for the NVIDIA GPU Operator driver pods on OpenShift.

⏱ 20 minutes K8s 1.28+

Deploy a New Certificate for Each OpenShift Tenant

Replace and activate new TLS certificates tenant by tenant in OpenShift IngressController deployments with verification steps and rollback guidance.

⏱ 30 minutes K8s OpenShift 4.12+

OpenShift Multi-Tenant TLS per IngressController

Set up tenant-isolated TLS in OpenShift by assigning a dedicated certificate Secret to each IngressController for multi-tenant routing security.

⏱ 20 minutes K8s OpenShift 4.12+

Rotate OpenShift Tenant Secrets Safely

Implement low-risk secret rotation in OpenShift multi-tenant environments using versioned Secrets and controlled rollouts.

⏱ 25 minutes K8s OpenShift 4.12+

Kyverno Policy Management and Enforcement

Implement Kubernetes-native policy management using Kyverno to validate, mutate, and generate resources with declarative policies written in YAML

⏱ 45 minutes K8s 1.28+

How to Configure Pod Security Context

Secure your Kubernetes pods with Security Context settings. Learn to set user/group IDs, file system permissions, capabilities, and privilege escalation.

⏱ 20 minutes K8s 1.28+

How to Use Sealed Secrets for GitOps

Encrypt Kubernetes secrets for safe Git storage with Sealed Secrets. Learn to seal, manage, and rotate secrets in GitOps workflows securely.

⏱ 25 minutes K8s 1.28+

How to Use Workload Identity for Cloud Access

Securely access cloud services from Kubernetes pods without static credentials. Configure Workload Identity for AWS, Azure, and GCP with IRSA, Workload.

⏱ 30 minutes K8s 1.28+

How to Manage Kubernetes Certificates with cert-manager

Automate TLS certificate management with cert-manager. Configure issuers, request certificates from Let's Encrypt, and enable automatic renewal.

⏱ 15 minutes K8s 1.28+

How to Implement Container Security Scanning

Scan container images for vulnerabilities before deployment. Integrate Trivy and other tools into CI/CD pipelines and runtime admission control.

⏱ 15 minutes K8s 1.28+

How to Scan Container Images for Vulnerabilities

Implement container image vulnerability scanning with Trivy, Grype, and other tools. Integrate scanning into CI/CD pipelines and admission control.

⏱ 15 minutes K8s 1.28+

How to Use External Secrets Operator

Sync secrets from external providers like AWS Secrets Manager, HashiCorp Vault, and Azure Key Vault into Kubernetes using External Secrets Operator.

⏱ 15 minutes K8s 1.28+

How to Implement Kyverno Policies

Enforce Kubernetes policies with Kyverno. Validate, mutate, and generate resources using declarative YAML policies without code.

⏱ 15 minutes K8s 1.28+

How to Configure Pod Security Admission

Enforce security standards with Pod Security Admission. Configure privileged, baseline, and restricted policies at namespace level for cluster-wide.

⏱ 15 minutes K8s 1.28+

How to Manage Kubernetes Secrets Securely

Best practices for managing secrets in Kubernetes. Learn encryption at rest, secret rotation, and integration with external secret stores.

⏱ 15 minutes K8s 1.28+

How to Configure Service Accounts and RBAC

Secure your Kubernetes workloads with service accounts and role-based access control. Create roles, bindings, and implement least-privilege access.

⏱ 15 minutes K8s 1.28+

How to Implement Pod Security Standards

Secure your Kubernetes workloads using Pod Security Standards (PSS). Learn to enforce Privileged, Baseline, and Restricted policies at the namespace level.

⏱ 25 minutes K8s 1.28+

How to Configure RBAC and Service Accounts

Master Kubernetes RBAC (Role-Based Access Control) to secure your cluster. Learn to create Roles, ClusterRoles, and bind them to ServiceAccounts.

⏱ 30 minutes K8s 1.28+

Advanced

OpenClaw RBAC and Multi-Tenant Isolation

Configure OpenClaw RBAC policies and namespace isolation for multi-tenant Kubernetes clusters with per-team agent access controls.

⏱ 15 minutes K8s 1.28+

OpenShift ACS for Kubernetes

Deploy and configure Red Hat Advanced Cluster Security (ACS/RHACS) for vulnerability scanning, compliance, network policies, and runtime threat detection.

⏱ 15 minutes K8s 1.28+

RHACS Custom System Policies

Create and manage custom security policies in Red Hat Advanced Cluster Security for image scanning, deployment config, and runtime enforcement.

⏱ 15 minutes K8s 1.28+

RHACS Multi-Cluster Management

Manage security across multiple Kubernetes clusters with RHACS Central hub, secured cluster registration, and unified policy enforcement.

⏱ 15 minutes K8s 1.28+

RHACS Network Segmentation Policies

Use Red Hat Advanced Cluster Security network graph to discover traffic flows, generate NetworkPolicies, and enforce micro-segmentation.

⏱ 15 minutes K8s 1.28+

Update CA Certificates in Kubernetes

Rotate and update Certificate Authority (CA) certificates in Kubernetes clusters including kube-apiserver, etcd, kubelet, and custom CA bundles for TLS.

⏱ 45 minutes K8s 1.28+

Secure Containers with gVisor Runtime

Enhance container isolation using gVisor sandbox runtime to add an additional security layer between containers and the host kernel for untrusted workloads

⏱ 45 minutes K8s 1.28+

How to Integrate HashiCorp Vault with Kubernetes

Securely manage secrets with HashiCorp Vault in Kubernetes. Learn to inject secrets into pods using the Vault Agent Injector and CSI Provider.

⏱ 40 minutes K8s 1.28+

OIDC Authentication for Kubernetes

Configure OpenID Connect (OIDC) authentication to integrate Kubernetes with identity providers like Keycloak, Okta, Azure AD, and Google for secure user.

⏱ 50 minutes K8s 1.28+

How to Create Admission Webhooks

Build validating and mutating admission webhooks to enforce policies and modify resources. Implement custom admission controllers for Kubernetes.

⏱ 15 minutes K8s 1.28+

How to Configure Kubernetes API Access Control

Set up secure API server access with authentication and authorization. Configure RBAC, API groups, and audit logging for cluster security.

⏱ 15 minutes K8s 1.28+

How to Configure Kubernetes Audit Logging

Enable and configure Kubernetes API audit logging. Track who did what, when, and to which resources for security compliance and troubleshooting.

⏱ 15 minutes K8s 1.28+

How to Use Kubernetes RuntimeClass

Configure different container runtimes for workloads. Use gVisor, Kata Containers, or other runtimes for enhanced security and isolation.

⏱ 15 minutes K8s 1.28+

How to Implement Advanced NetworkPolicies

Master advanced Kubernetes NetworkPolicies for fine-grained traffic control. Learn egress rules, CIDR blocks, namespace isolation, and common security.

⏱ 15 minutes K8s 1.28+

How to Encrypt Secrets at Rest with KMS

Configure Kubernetes secrets encryption at rest using external KMS providers. Learn to set up AWS KMS, GCP KMS, and Azure Key Vault encryption.

⏱ 15 minutes K8s 1.28+

Want more security patterns?

Our book includes an entire chapter dedicated to security with dozens more examples.

📖 Explore All Chapters
Luca Berton Ansible Pilot Ansible by Example Open Empower K8s Recipes Terraform Pilot CopyPasteLearn ProteinLens