The multiple repository pattern separates infrastructure-as-code configurations or modules into repositories organized by team or function. Each module follows its own lifecycle, while teams download and import the versions they need. section 5.1.2
Apply the pattern by:
- Creating separate version-control repositories for modules and environment configurations. section 5.1.2
- Referencing modules through repository URLs and specific Git tags rather than local paths. section 5.1.2
- Organizing repositories by business domain, function, team, or environment, with consistent naming. section 5.5
- Adding governance, formatting checks, and versioning practices so independent repositories remain compatible and safe. section 5.1.3 section 5.5
Production configuration with remote modules
A production repository can list tagged tags, network, server, and database modules in requirements.txt, install them from Git repositories, and import them into the infrastructure configuration. section 5.1.2
Figure 5.3 In a multiple repository structure, you store each module in its own code repository. The configuration references the repository URL to use the module.
Use the repository layout diagram to see how each module receives its own repository and how configuration references its repository URL. section 5.1.2
