Skip to content

Infrastructure Naming Standard

Version 1.0 — Applies to all new AWS infrastructure managed via Terraform. Legacy resources keep existing names until migrated.

Purpose

  • Ensure consistency across regions and environments
  • Support long-term scalability
  • Simplify automation and auditing
  • Replace legacy numeric server naming
  • Align with AWS and modern infrastructure practices

Core Naming Format

All AWS resource names must follow this format:

<environment>-<region>-<group>-<service>[-<index>]

Examples:

prod-euc1-vault-clickhouse
prod-euc1-vault-clickhouse-1
prod-euc1-vault-ecs-cluster
prod-euc1-vault-internal-alb
stage-euc1-vault-etl-worker
prod-euw1-atrax-api

Components

Environment

Environment Value
Production prod
Staging stage
Testing test
Development dev

Region

AWS Region Code
eu-central-1 euc1
eu-west-1 euw1

Define a short code for any new region before use.

Group

Group Description
core Core application services
vault Consent storage and processing
edge Edge delivery systems
atrax Atrax subsystem
common Shared infrastructure components

Service

Descriptive logical service name. Must be stable across deployments. Avoid abbreviations unless widely understood.

Examples: clickhouse, ecs-cluster, etl-worker, api, internal-alb, sqs-ingest, iam-role, security-group

Index (optional)

Used only when multiple fixed instances exist (e.g. replica pairs, explicit cluster members). Do not use indexes for autoscaled or dynamic services.

prod-euc1-vault-clickhouse-1
prod-euc1-vault-clickhouse-2

DNS Naming Standard

Internal services use service-based DNS, not host-based DNS.

Private hosted zone: internal.cookiehub.net

Format:

<service>.<group>.<environment>.internal.cookiehub.net

Examples:

clickhouse.vault.prod.internal.cookiehub.net
api.vault.prod.internal.cookiehub.net

Cluster nodes (when needed):

clickhouse-1.vault.prod.internal.cookiehub.net
clickhouse-2.vault.prod.internal.cookiehub.net

Clients must connect to service-level DNS, not individual node DNS.


AWS Tagging Standard

All Terraform-managed resources must include these tags:

Tag Key Example Value
Name prod-euc1-vault-clickhouse
Environment prod
Region eu-central-1
Group vault
Service clickhouse
ManagedBy terraform

Optional but recommended:

Tag Key Purpose
Owner Team or responsible person
CostCenter Finance mapping
Criticality low, medium, high

Tags are mandatory identity. Hostnames are not primary identifiers.


Principles

  1. Name logical services, not machines.
  2. Avoid numeric naming unless technically required.
  3. Keep names human-readable.
  4. Keep names stable across deployments.
  5. Do not encode implementation details in names.
  6. Use tags as first-class metadata.
  7. Prefer descriptive names over short cryptic codes.

Examples Summary

Resource Type Name Example
ClickHouse EC2 prod-euc1-vault-clickhouse
ClickHouse replica prod-euc1-vault-clickhouse-2
ECS Cluster prod-euc1-vault-ecs-cluster
Internal ALB prod-euc1-vault-internal-alb
SQS Queue prod-euc1-vault-sqs-ingest
IAM Role prod-euc1-vault-ecs-task-role

Legacy Infrastructure

Existing infrastructure using the old numeric naming system remains unchanged until replaced. All new infrastructure must follow this document. Migration occurs gradually during refactors or system upgrades.