Skip to content

Latest commit

 

History

History
54 lines (39 loc) · 2.11 KB

application_definition.md

File metadata and controls

54 lines (39 loc) · 2.11 KB
page_title cozystack_application_definition Resource - cozystack
subcategory
description A Cozystack ApplicationDefinition (cluster-scoped, cozystack.io group): registers a tenant application kind. The spec is a platform document, surfaced as JSON.

cozystack_application_definition (Resource)

A Cozystack ApplicationDefinition (cluster-scoped, cozystack.io group): registers a tenant application kind. The spec is a platform document, surfaced as JSON.

Example Usage

resource "cozystack_application_definition" "example" {
  name = "example"
  spec = jsonencode({
    application = { kind = "Example", plural = "examples", singular = "example", openAPISchema = "" }
    release     = { prefix = "example-", chartRef = { kind = "HelmRepository", name = "example" } }
  })
}

Schema

Required

  • name (String) ApplicationDefinition name (metadata.name). Immutable.

Optional

  • spec (String) Full ApplicationDefinition spec as JSON (application, release, selectors, dashboard).
  • wait_for_ready (Boolean) Block on create/update until the Ready condition is true and any server-generated outputs the resource exposes are readable.
  • wait_timeout (String) Maximum time to wait when wait_for_ready is set (Go duration, e.g. 10m). Readiness and outputs share this budget; outputs that never appear leave a warning and their attributes stay null until the next refresh.

Read-Only

  • chart_version (String) Deployed chart version (status.version).
  • id (String) Object name (cluster-scoped).
  • ready (Boolean) Whether the application's Ready condition is true.
  • uid (String) Server-assigned object UID (metadata.uid). Stable across updates; changes on recreate.

Import

Import is supported using the following syntax:

The terraform import command can be used, for example:

# Cluster-scoped: import by name only.
terraform import cozystack_application_definition.example name