mirror of
https://gitlab.sarex.io/infra/terraform-contour-mirror.git
synced 2026-08-08 13:11:35 +03:00
- Add infrastructure.yaml as single source of truth (like values.yaml in Helm) - Make all modules universal (no hardcoded entity names) - Use existing PostgreSQL cluster instead of creating new one - Add yc-database module for working with existing PostgreSQL - Add k8s-secret module with lifecycle.ignore_changes support - Update terragrunt.hcl files to read from infrastructure.yaml - Remove scripts, use native Terragrunt functions (yamldecode)
65 lines
2.0 KiB
YAML
65 lines
2.0 KiB
YAML
# Единый конфигурационный файл инфраструктуры
|
|
# Аналог values.yaml в Helm
|
|
|
|
environments:
|
|
stage:
|
|
namespaces:
|
|
- name: pulse
|
|
labels:
|
|
environment: stage
|
|
project: pulse
|
|
annotations:
|
|
managed-by: terraform
|
|
|
|
secrets:
|
|
- name: dockerhub
|
|
namespace: pulse
|
|
type: dockerconfigjson
|
|
registry_url: cr.yandex
|
|
# username и password из переменных окружения
|
|
|
|
- name: pulse-s3-secret
|
|
namespace: pulse
|
|
type: opaque
|
|
keys:
|
|
access_key: "" # Заполнится из outputs модуля s3
|
|
secret_key: "" # Заполнится из outputs модуля s3
|
|
bucket: "" # Заполнится из outputs модуля s3
|
|
endpoint: https://storage.yandexcloud.net
|
|
lifecycle:
|
|
ignore_changes: true
|
|
|
|
- name: pulse-postgresql-secret
|
|
namespace: pulse
|
|
type: opaque
|
|
keys:
|
|
host: "" # Заполнится из outputs модуля database
|
|
port: "6432"
|
|
database: "" # Заполнится из outputs модуля database
|
|
user: "" # Заполнится из outputs модуля database
|
|
password: "" # Заполнится из outputs модуля database
|
|
lifecycle:
|
|
ignore_changes: true
|
|
|
|
buckets:
|
|
- name: pulse
|
|
acl: public-read
|
|
versioning:
|
|
enabled: false
|
|
cors:
|
|
enabled: true
|
|
allowed_headers: ["*"]
|
|
allowed_methods: ["GET", "PUT", "POST", "DELETE", "HEAD"]
|
|
allowed_origins: ["*"]
|
|
expose_headers: ["ETag"]
|
|
max_age_seconds: 3600
|
|
|
|
databases:
|
|
- cluster_id: pg-stage # ID существующего кластера PostgreSQL
|
|
database:
|
|
name: pulse_db
|
|
user:
|
|
name: pulse
|
|
password_length: 32
|
|
password_special: false
|