Skip to content

CivCloud: Subsystems

James Lott edited this page Aug 5, 2020 · 2 revisions

Ingest

The Ingest Subsystem is responsible for taking input from end users and from administrators and producing Project Resources and Cloud Sites from each input respectively.

v0.1.0 Implementation

Input sources

  1. Project Resources: These are sourced from an annotated docker-compose file.
  2. Cloud Sites: These are not fully implemented; their function at the time of this release is fulfilled by administrator specified Ansible inventory variables.

Canonical Playbooks

  • project-intake.yml: Must be passed a git url, a git ref, and a subpath to a docker-compose file (optional, defaults to /docker-compose.yml). Produces project resources in yaml representation.
  • system-project-intake.yml: Must be passed a git url, a git ref, and a subpath to a docker-compose file (optional, defaults to /docker-compose.yml)

Deployment

The Deployment Subsystem consumes the entities produced by the Ingest Subsystem, produces deployment configurations in a format consumable by the Infrastructure backend, and pushes/activates those configurations to the infra backend.

v0.1.0 Implementation

Canonical Playbooks

  • projects-deploy.yml: Consumes entities for all projects and remediates desired backend state; create & deploy projects where they don't exist, scale services in or out as requested, build & deploy updated versions where required.
  • system-project-deploy.yml: Same as projects-deploy, but specifically for deploying the system project.

Sub Playbooks

  • inventory-project-instance.yml: Dynamically creates inventory entries for every node placement/project combination. E.g., if a project is deployed to both node1 and node2, this playbook would create a myproject.node1 and myproject.node2 inventory entry so that both can be deployed simultaneously.

Infrastructure

The Infrastructure Subsystem deals with the backend infrastructure implementation and any workflows needed to manage it.

v0.1.0 Implementation

The only backend infrastructure implementation in the v0.1.0 release is pure docker. The only OS supported in this release is Arch Linux.

Canonical Playbooks

Sub Playbooks

  • node-init.yml: Performs all baseline configuration required in order to properly manage a node via Ansible. This playbook exclusively uses calls to Ansible's raw module since the dependencies for native Ansible management are not yet guaranteed to exist.
  • node-patch.yml: Patches a linux system, rebooting it if necessary.
  • node-base.yml: Deploys the CivCloud infrastructure stack to the node
  • node-base-systemdb.yml: Initializes the node's "systemdb", which is its local record of desired state.

Clone this wiki locally