DevOps: overview
The DevOps part makes sure every commit is tested, built and released automatically, to dev then to prod, with zero downtime and without any secret written in the repository.
At a glance
| Topic | Detail |
|---|---|
| Folders | .gitlab-ci.yml, infra/, and the .gitlab-ci.yml files of api/ and web/ |
| Languages | YAML (pipeline, Compose, Traefik, Ansible), shell |
| CI/CD | GitLab CI, 4 stages: lint, test, build, deploy |
| Runners | 3 self-hosted runners on 2 Google Cloud |
| Containers | ; in dev, in prod |
| Traffic entry | v3.6, HTTPS |
| Server configuration | , secrets in |
| Addresses | https://trinity.jostud.com, https://dev.trinity.jostud.com and their api. subdomains, plus https://docs.trinity.jostud.com for these docs |
| Owner | Elias |
What the part does
Its architecture
- Ansible prepares both machines: Docker, firewall, Traefik, runners.
- The runners fetch work from GitLab: no connection comes into the servers from GitLab.
- The CI runner does lint, tests and build. The deploy runners run directly on their server.
Before you start
If CI/CD, runner, image or reverse proxy mean nothing to you, read The basics first.
Going further
| You want… | Read |
|---|---|
| the full pipeline diagram | The pipeline |
| the differences between dev and prod | Dev and prod environments |
| to install or fix a runner | Runners |
| to understand zero-downtime deployment | Zero-downtime deployment |
| to see the machines, the firewall and DNS | Infrastructure |
| to know every network connection | Flow matrix |
| to know where the secrets are | Secrets and access |
| to react to an outage | If the site goes down |