# OCI Deal Accelerator — Architecture Diagram Spec
# Demo: PharmaCorp Mexico — ExaCS dual-region with Data Guard
# Prompt: "ExaCS en Queretaro (prod) + Standby con Data Guard en Sao Paulo,
#          Hub-Spoke networking con DRG, FastConnect 10Gbps dual desde Mexico City,
#          bastion en public subnet, WAF para apps web, Vault para TDE keys."
#
# REQUESTED by user: ExaCS (prod+DR), DRG, FastConnect dual, Bastion, WAF, Vault
# TECHNICAL DEPENDENCIES (whitelist): SGW (ExaCS backup), IGW (public subnet)
# NOT included: EBS, Monitoring, Logging, Events, FSDR, Object Storage (not requested)
#
# Container sizes: omitted to let auto-sizing calculate from content.
# DRG: listed in gateways — generator places it OUTSIDE VCN, INSIDE region.

title: "PharmaCorp Mexico — ExaCS Migration Architecture"

# External: Mexico City DC (left side)
external:
  - id: "mexico_dc"
    label: "Mexico City\nData Center"
    icon: "user"
    x: 30
    y: 250
    w: 60
    h: 70

# OCI Tenancy
tenancy:
  label: "Oracle Cloud Infrastructure"
  x: 200
  y: 60

  regions:
    # ── Primary Region: Queretaro ──
    - id: "region_qro"
      label: "Region — Queretaro (Primary)"
      primary: true

      vcns:
        - id: "vcn_hub"
          label: "Hub VCN (10.0.0.0/16)"

          subnets:
            # Public subnet — WAF + Bastion (both requested)
            - id: "subnet_pub"
              label: "Public Subnet — 10.0.0.0/24"
              h: 120
              services:
                - id: "waf"
                  label: "WAF\n(Web Apps)"
                  type: "waf"
                  w: 120
                  h: 70
                - id: "bastion"
                  label: "Bastion\nService"
                  type: "bastion"
                  w: 120
                  h: 70

            # DB subnet — ExaCS + Vault (both requested)
            - id: "subnet_db"
              label: "Database Subnet (Private) — 10.0.1.0/24"
              h: 130
              services:
                - id: "exacs_prod"
                  label: "ExaCS X11M\nQuarter Rack\n(Production)"
                  type: "exacs"
                  w: 200
                  h: 80
                - id: "vault"
                  label: "OCI Vault\nTDE Keys"
                  type: "vault"
                  w: 140
                  h: 80

          gateways:
            # DRG — generator places this OUTSIDE VCN, INSIDE region
            - id: "drg"
              label: "DRG"
              type: "drg"
            # IGW — whitelist: public subnet requires it
            - id: "igw"
              label: "Internet\nGateway"
              type: "igw"
            # SGW — whitelist: ExaCS backup requires it
            - id: "sgw"
              label: "Service\nGateway"
              type: "service_gateway"

    # ── DR Region: Sao Paulo ──
    - id: "region_gru"
      label: "Region — São Paulo (DR)"

      vcns:
        - id: "vcn_dr"
          label: "DR VCN (10.1.0.0/16)"

          subnets:
            - id: "subnet_dr_db"
              label: "DB Subnet (Private) — 10.1.1.0/24"
              h: 130
              services:
                - id: "exacs_dr"
                  label: "ExaCS Standby\n(Data Guard)"
                  type: "exacs"
                  w: 200
                  h: 80

# Connections
connections:
  # FastConnect dual from Mexico City → DRG (will be merged into single edge)
  - id: "conn_fc1"
    label: "FastConnect 10Gbps\n(Dual Redundant)"
    type: "fastconnect"
    from: "mexico_dc"
    to: "drg"

  # Vault → ExaCS (TDE keys)
  - id: "conn_vault"
    label: "TDE Keys"
    type: "internal"
    from: "vault"
    to: "exacs_prod"

  # Data Guard: Prod → DR
  - id: "conn_dg"
    label: "Data Guard\n(Redo Shipping)"
    type: "data"
    from: "exacs_prod"
    to: "exacs_dr"
