Commit Graph

3 Commits

Author SHA1 Message Date
darnodo
a02582aaea ci(workflow): hardcode gitea server url in terraform workflow
Some checks failed
Terraform CI/CD / Validate (push) Failing after 2s
Terraform CI/CD / Plan (push) Has been skipped
Terraform CI/CD / Apply (push) Has been skipped
Replaces the dynamic `${{ gitea.server_url }}` variable with the explicit URL `https://gitea.arnodo.fr` in the Terraform workflow configuration. This change affects git clone operations and API calls for posting PR comments, likely to resolve issues with variable expansion or DNS resolution within the runner environment.
2025-12-08 11:31:46 +01:00
ba4b530635 fix(ci): replace actions/checkout with git clone
Some checks failed
Terraform CI/CD / Validate (push) Failing after 1s
Terraform CI/CD / Plan (push) Has been skipped
Terraform CI/CD / Apply (push) Has been skipped
- Remove actions/checkout@v4 (requires Node.js not in Alpine image)
- Use native git clone instead
- Remove actions/upload-artifact and download-artifact (require Node.js)
- Re-run plan in apply job instead of artifact transfer
- Add workflow file to paths trigger for testing

Refs #3
2025-12-08 09:00:24 +00:00
6036783cd5 feat(ci): Add Terraform CI/CD pipeline (#4)
## Description

Mise en place d'un pipeline CI/CD Gitea Actions pour automatiser le déploiement Terraform.

## Changements

- Ajout du workflow `.gitea/workflows/terraform.yml`
- Utilisation de l'image custom `gitea.arnodo.fr/damien/terraform-ci:latest` (Terraform 1.5.7 + TFLint)
- Exécution dans des containers Docker (pas sur le host)

## Pipeline

| Job | Trigger | Actions |
|-----|---------|---------|
| **validate** | Push + PR | `terraform fmt -check`, `tflint`, `terraform validate` |
| **plan** | Push + PR | `terraform plan` + commentaire automatique sur la PR |
| **apply** | Push sur `dev` uniquement | `terraform apply` (si changements détectés) |

## Secrets configurés

- [x] `AWS_ACCESS_KEY_ID`
- [x] `AWS_SECRET_ACCESS_KEY`
- [x] `PROXMOX_URL`
- [x] `PROXMOX_API_TOKEN`
- [x] `TAILSCALE_AUTH_KEY`
- [x] `GIT_TOKEN`

## Test

Cette PR va déclencher les jobs `validate` et `plan`. Le job `apply` se déclenchera après le merge sur `dev`.

Closes #3

Reviewed-on: #4
2025-12-08 08:52:43 +00:00