Introduction
Le deployer transforme un fichier deployer.yaml en infrastructure complete sur Google Cloud Platform et Kubernetes.
Ce que fait le deployer
Section intitulée « Ce que fait le deployer »A partir d’un seul fichier de configuration, le deployer :
- Cree les ressources GCP : service accounts, bases de donnees, buckets, topics PubSub
- Deploie sur Kubernetes : deployments, services, probes, VPA, workers, cronjobs
- Configure le reseau : Gateway API (Envoy), DNS, TLS (cert-manager), CORS, redirections
- Gere les secrets : integration Vault pour les variables d’environnement
Architecture
Section intitulée « Architecture »flowchart TD
A["deployer.yaml"] -->|parse| B["Platform"]
B -->|"ApplyDefaultsOrchestrator"| C{"8 etapes"}
C --> D["Databases"]
C --> E["Pub/Sub"]
C --> G["Buckets"]
C --> H["Cloud Functions"]
C --> I["K8s Inputs"]
C --> J["Vault Secrets"]
I --> I3["Network + DNS"]
I --> I4["Gateway API"]
I --> I5["Workers / CronJobs"]
C -->|prettify| K["PrettyPlatform"]
K -->|YAML| L["platform-pretty.yaml"]
L -->|yamldecode| M["Terraform"]
M --> N["gke/"]
M --> O["gateway-api/"]
M --> P["dns/"]
M --> Q["bucket/"]
M --> R["pubsub/"]
M --> S["cloud-function/"]
Flux de deploiement
Section intitulée « Flux de deploiement »sequenceDiagram
participant CI as GitHub Actions
participant D as Deployer CLI
participant TF as Terraform
participant GCP as Google Cloud
participant K8s as Kubernetes
CI->>D: deployer deploy
D->>D: Parse deployer.yaml
D->>D: ApplyDefaultsOrchestrator
D->>D: Prettify → YAML
D->>TF: terraform init + plan
TF->>GCP: Service accounts, DNS, Buckets, Pub/Sub
TF->>K8s: Deployments, Services, ConfigMaps
TF->>K8s: Gateway API (HTTPRoute, Policies)
TF-->>D: Apply complete
D-->>CI: deploy.url
Types d’applications supportes
Section intitulée « Types d’applications supportes »flowchart LR
subgraph Web
W1["Deployment K8s"]
W2["Service ClusterIP"]
W3["HTTPRoute"]
W4["EnvoyExtensionPolicy"]
end
subgraph "Static / Spa"
S1["Bucket GCS"]
S2["HTTPRoute static"]
S3["Backend GCS"]
end
subgraph Infra
I1["Terraform only"]
I2["Pas de pods"]
end
| Type | Description | Exemple |
|---|---|---|
| Web | Application avec pods K8s | API Node.js, app PHP/Symfony |
| Static | Fichiers statiques sur GCS | Site marketing, portail |
| Spa | Single Page Application sur GCS | App Vue.js, React |
| Infra | Terraform uniquement, pas de pods | Infrastructure pure |
Conventions
Section intitulée « Conventions »- URL :
{name}-{branch}.homeserve.io(preview),{host}(prod) - Namespace : defaut =
name - Replicas : 3 (prod), 2 (non-prod)
- Resources : adaptes par environnement (voir Valeurs par defaut)