-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.tf
More file actions
32 lines (27 loc) · 1.47 KB
/
main.tf
File metadata and controls
32 lines (27 loc) · 1.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#####################################################################################
# Terraform module examples are meant to show an _example_ on how to use a module
# per use-case. The code below should not be copied directly but referenced in order
# to build your own root module that invokes this module
#####################################################################################
#####################################################################################
# Hosting Account — AgentSpace Deployment
#
# This example deploys an AgentSpace in the dedicated hosting (hub) account.
# Run this first. After applying, use the agent_space_arn output to configure
# the cross-account role in each workload account (see examples/spoke/).
#
# PHASE 1: Apply with secondary_accounts = {} (default). Capture agent_space_arn.
# PHASE 2: Populate secondary_accounts with spoke role ARNs and re-apply.
#####################################################################################
module "devops_agent" {
source = "appvia/devops-agent/aws"
version = "~> 0.1"
agent_space_name = var.agent_space_name
name_prefix = var.name_prefix
agent_space_description = var.agent_space_description
agentspace_region = var.agentspace_region
# Phase 1: leave empty — apply and capture the agent_space_arn output.
# Phase 2: add an entry per workload account once the spoke role ARN is known.
secondary_accounts = var.secondary_accounts
tags = var.tags
}