Skip to main content

Infrx Assets & Cluster Stacks

This document covers how to manage infrastructure-level (infrx) assets and cluster stacks — the set of cluster-level components that run on your Kubernetes clusters.


Concepts

Infrx Assets vs. SDLC Assets

Codiac manages two classes of software assets:

SDLC assets are the application workloads that make up your product: APIs, services, frontends, databases, third-party containers. They follow a Software Development Lifecycle — built, tested, versioned, and deployed into cabinets isolated by environment.

Infrx assets are cluster-level components that support the cluster itself rather than running your business logic. Examples: an NGINX ingress controller, a TLS cert manager, a cluster autoscaler, a metrics server.

The key conceptual difference: SDLC assets are deployed to cabinets within an enterprise. Infrx assets are installed to clusters, because they operate at the cluster level, not at the namespace/tenant level.

Both asset classes use the same underlying Codiac machinery — versions, snapshots (called cluster stacks in the infrx context), configuration, and the same CLI patterns. The different terminology (install/uninstall vs. deploy/undeploy, cluster stack vs. snapshot) is intentional: it reduces the chance of confusing the two in conversation and in practice.


The k8sinfrx Enterprise

All infrx assets live in a single built-in enterprise called k8sinfrx. Every Codiac tenant has this enterprise automatically.

Note: The k8sinfrx enterprise is currently identified by name. A future release will support flagging any enterprise as an infrastructure enterprise, enabling multiple infrx enterprises for more advanced multi-cluster architectures.

You can see the assets in your k8sinfrx enterprise with:

cod asset list -e k8sinfrx

Namespaces

Individual infrx assets can declare a namespace configuration that controls which Kubernetes namespace the asset is installed into. If an asset has no namespace config, it is installed into the default infrx asset namespace.

To set the namespace for an infrx asset, use cod config set targeting the k8sinfrx enterprise and the asset in question, setting the [namespace] config key.


Cluster Stacks

A cluster stack is the infrx equivalent of a Codiac snapshot: a named, versioned list of infrx assets at specific versions, all intended to be installed together as a coherent set of cluster components.

The Default Cluster Stack

Codiac ships with a preconfigured default cluster stack. The default stack is the latest EnterpriseVersionConfig in the k8sinfrx enterprise tagged as default. Out of the box, it contains:

  • NGINX ingress controller
  • Jetstack cert-manager (TLS certificate management)
  • Cluster autoscaler
  • Codiac in-cluster agent

If you just want a functioning cluster without thinking about individual components, run:

cod cluster stack install

and accept the defaults. You will get a cluster equivalent to what cod cluster init used to produce, but now with full visibility and control over every component.


Listing Available Cluster Stacks

# List all cluster stacks
cod cluster stack list

# In a specific output format
cod cluster stack list -o yaml

# Filter with JMESPath — show only stacks tagged "default"
cod cluster stack list -q "[?tags[?name == 'default']]"

Installing a Cluster Stack

# Interactive — select version and cluster
cod cluster stack install

# Scripted — specify version and target cluster
cod cluster stack install -v <version> -c <cluster-name> --silent

Before running this, the Codiac in-cluster agent must already be installed on the target cluster. See Codiac Agent Reference.


Installing a Single Infrx Asset

To install or update a single infrx asset without touching the rest of the stack:

cod cluster install

This works the same as cod asset deploy for SDLC assets, but targets a cluster. The CLI enforces this — if you accidentally run cod asset deploy targeting the k8sinfrx enterprise, it will redirect you to use cod cluster install instead, and vice versa.


Capturing the Built-In Stack

cod cluster stack capture is a setup utility, not a day-to-day command. It reads Codiac's preconfigured set of cluster components and loads them as asset records and configuration into your k8sinfrx enterprise.

When to run it: Run cod cluster stack capture once during initial Codiac onboarding, or when you want to reset your k8sinfrx enterprise to Codiac's baseline set of preconfigured cluster components.

Note: Running cod cluster stack capture will overwrite any existing infrx assets with the same names and any matching settings at the enterprise level. It does not delete existing settings — only overwrites matches. It does not modify any live cluster.

# Capture the default Codiac cluster stack
cod cluster stack capture

# Capture a named stack
cod cluster stack capture my-custom-stack

After capturing, you can inspect the loaded assets:

cod asset list -e k8sinfrx
cod cluster stack list

Managing Infrx Assets Over Time

Updating a Component Version

Infrx assets follow the same versioning workflow as SDLC assets:

  1. Update the asset version record in Codiac
  2. Create a new cluster stack snapshot that references the new version
  3. Tag the new snapshot as default if you want it to be the default going forward
  4. Run cod cluster stack install to push the updated stack to target clusters

Adding a Custom Component

You can define your own infrx assets (any Helm chart or container) and add them to your cluster stack:

  1. Create the asset in the k8sinfrx enterprise: cod asset create
  2. Configure it: cod config set ...
  3. Version and tag it: cod snapshot create
  4. Install it to a cluster: cod cluster install (single asset) or include it in a stack and run cod cluster stack install

Uninstalling a Component

cod cluster uninstall

Command Reference

GoalCommand
List infrx assetscod asset list
List cluster stackscod cluster stack list
Install a stackcod cluster stack install
Install a single assetcod cluster install
Uninstall a single assetcod cluster uninstall
Load Codiac's default componentscod cluster stack capture