Course contentsShow
← Cloud and Infrastructure
Lesson 956 of 2,98918. Google Cloud Deployment ManagerFree lesson

Composite Type Configuration Files

Structure composite types with template and schema files for reusability.

Composite Type Configuration Files

Important Legacy Notice: Google Cloud Deployment Manager reached end of support on March 31, 2026. This material is provided strictly as a legacy reference for maintaining existing deployments. Direct all new infrastructure work to Google Cloud Infrastructure Manager or Terraform.

What you'll learn: How legacy composite types were organized using separate template and schema files to make Deployment Manager resources reusable across multiple deployments.

Why Structure Matters

When reviewing existing Deployment Manager configurations, you will notice that custom composite types were properly packaged using two separate files: a template file (the "what") and a schema file (the "how").

Think of it like a recipe card: the template contains the execution instructions, while the schema acts as the ingredient list with measurements and types. Keeping them separate provided clarity and reuse for legacy infrastructure code.

The Two-File Structure

Template File (.jinja, .py, or .yaml):

  • Contains the actual resource definitions.
  • Implements the logic that originally provisioned Google Cloud resources.
  • References properties defined in the schema.

Schema File (.yaml or .jinja.schema):

  • Defines what inputs (properties) the template accepts.
  • Specifies data types, descriptions, and default values.
  • Acts as a strict contract between the template and the consumer.

Historically, administrators registered these types using gcloud deployment-manager commands (which should now only be referenced for maintaining existing setups, not creating new ones). By pointing to both files, the schema validated incoming configuration parameters before the template ran, catching errors early and making the composite type self-documenting.

Naming Convention

If a legacy template was named my-component.jinja, its schema was conventionally named my-component.jinja.schema. This naming convention helped Deployment Manager automatically locate paired files within a project.

Key Takeaway: Legacy Deployment Manager composite types relied on a two-file structure—template files defined the resources, while schema files defined the accepted inputs—enabling validation, documentation, and reusability for historical deployments.