Point-out Docs

Point-out's infrastructure is defined with OpenTofu in point-out/infrastructure and applied by GitHub Actions, to one AWS account per environment. Resources live in eu-central-1, except those AWS only accepts in us-east-1, such as CloudFront certificates.

Components

Each component has its own page, covering its architecture and its deployment.

ComponentWhat it is
OpenTofuthe state account, the pipeline roles, the account settings and the plan/apply workflows
DNSthe Route 53 hosted zone of the environment's root domain
Docs sitethis portal: a private S3 bucket behind CloudFront, and how point-out/docs publishes to it
lambda-tsthe ingest API and the job worker of point-out/lambda-ts: two functions, their queue and an hourly ping

Environments

StagingProduction
AWS account468351713122not created yet
Root domain (hosted zone)staging2.point-out.netpoint-out.net
Docsdocs.staging2.point-out.netdocs.point-out.net
Account aliaspoint-out-staging-v2point-out-production-v2
Console colourgreenyellow
Applied onpush to stagingpush to main, once enabled
Valuesstaging.tfvarsproduction.tfvars

Production is disabled in the pipeline until its account exists. See OpenTofu.

Design rules

RuleWhere
One AWS account per environment; the OpenTofu state and the pipeline's secrets live in a separate state accountOpenTofu
Pipelines use GitHub OIDC roles instead of stored AWS keysOpenTofu, Docs site
Per-environment values are typed variables in the committed tfvars; secrets come from SSM at run timeOpenTofu
Buckets are private; CloudFront reads them through Origin Access ControlDocs site
The GitHub resources a deploy needs (environment, variables, deploy keys) are managed in this stack tooDocs site

Repository layout

PathContents
main.tfrequired providers, the aws provider (eu-central-1) and its aws.us_east_1 alias, the github provider, the account alias and console settings
config.tffixed locals: project = "point-out" and the default tags
variables.tfenvironment, root_domain, docs_allowed_ips, github_app_pem_file
staging.tfvars, production.tfvarsthe non-secret per-environment values
dns.tfthe Route 53 hosted zone and its name_servers output
modules.tfwires the docs-site and lambda-ts modules
outbound-federation.tfturns on IAM outbound identity federation for the account: the issuer of the tokens the lambda-ts API accepts
docs-site/bucket, distribution, viewer-request function, certificate, alias record, deploy role, GitHub environment and deploy keys
lambda-ts/the image registry and CI deploy role, the API and worker functions, the job queue, the ping schedule, the API's distribution and its client roles
.github/workflows/checkov.yml, plan.yml, apply.yml, trigger-apply.yml and the reusable tofu.yml
docs/infrastructure/, docs/aws-icons/this documentation and its diagram icons

On this page