Piceli Templates for Kubernetes Objects#
Piceli templates offer a structured, Pythonic way to define Kubernetes objects, enhancing readability and maintainability of your infrastructure code. These templates are part of Piceli’s Python module and are divided into deployable objects and auxiliary objects to support their definition.
Deployable Objects#
Deployable objects can be directly applied to a Kubernetes cluster. They encompass the essential Kubernetes resources necessary for deploying and managing applications.
Autoscaler: Automatically scale your applications based on metrics. Autoscaler Templates
ConfigMap: Manage application configurations and settings. ConfigMap
CronJob: Schedule jobs to run at specific times or intervals. CronJob
Deployment: Manage stateless applications deployed across your cluster. Deployment (based in )
Job: Execute short-lived or batch jobs within your cluster. Job
Role and ClusterRole: Define permissions for accessing Kubernetes resources. Roles and Role Bindings in Kubernetes with Piceli
RoleBinding and ClusterRoleBinding: Associate roles with specific users or groups. RoleBinding and ClusterRoleBinding
Secret: Securely store and manage sensitive information. Secret
Service: Define how to access applications running within your cluster. Service and ServicePort
ServiceAccount: Provide an identity for processes running within your cluster. ServiceAccount
StatefulSet: Manage stateful applications and their storage requirements. StatefulSet (based in )
Volume: Manage persistent storage for your applications. Volumes in Kubernetes with Piceli
Auxiliary Objects#
Auxiliary objects provide additional configurations and are often used in conjunction with deployable objects to fine-tune resource definitions.
Container: Specify container images, commands, and arguments. Container
Crontab: Define the schedule for running CronJobs. CronTab
EnvVars: Set environment variables for your containers. Environment Variables
Labels: Apply labels to Kubernetes objects for organization and selection. Labels
Names: Establish naming conventions for your Kubernetes objects. Kubernetes Identifiers and Names
Pod: Configure the pods that house your containers. Pod Template
PodSecurityContext: Set security settings at the pod level. Pod Security Context
Port: Define networking ports for your services and containers. Port Configuration
Quantity: Specify resources like CPU and memory allocations. Quantity Validation
ReplicaManager: Abstract class with the common implementation of Deployment and StatefulSet. ReplicaManager
ResourceRequest: Detail resource requests and limits for optimal scheduling. Resources Arithmetic in Kubernetes
Piceli templates not only facilitate a more organized and readable codebase but also enhance the manageability of Kubernetes resources. Explore the detailed documentation for each template to fully leverage Piceli in your Kubernetes deployments.
Examples#
Each object type is accompanied by examples demonstrating its use. Explore the examples to learn how to define and use these objects in your Piceli projects.
Piceli templates simplify the definition of Kubernetes objects, making it easy to manage your infrastructure as code. The examples provided offer a starting point for integrating Piceli templates into your project.