feat: add smtp info

This commit is contained in:
Yuris Cakranegara
2025-06-08 14:40:44 +10:00
parent 6f5965b71a
commit 8872662212
2 changed files with 42 additions and 0 deletions

View File

@@ -9,3 +9,10 @@ CLOUDFLARE_API_TOKEN="your-cloudflare-api-token"
CLOUDFLARE_ACCOUNT_ID="your-cloudflare-account-id"
CLOUDFLARE_ZONE_ID="your-cloudflare-zone-id"
DOMAIN="yourdomain.com"
# SMTP
MAIL_FROM=your-email@example.com
MAIL_HOST=smtp.gmail.com
MAIL_PORT=587
MAIL_USERNAME=your-email@example.com
MAIL_PASSWORD=your-smtp-password

View File

@@ -0,0 +1,35 @@
terraform {
required_providers {
dotenv = {
source = "germanbrew/dotenv"
}
}
}
data "dotenv" "smtp_config" {}
// Outputs
output "mail_from" {
description = "Mail from address"
value = data.dotenv.smtp_config.entries.MAIL_FROM
}
output "mail_host" {
description = "Mail host"
value = data.dotenv.smtp_config.entries.MAIL_HOST
}
output "mail_port" {
description = "Mail port"
value = data.dotenv.smtp_config.entries.MAIL_PORT
}
output "mail_username" {
description = "Mail username"
value = data.dotenv.smtp_config.entries.MAIL_USERNAME
}
output "mail_password" {
description = "Mail password"
value = data.dotenv.smtp_config.entries.MAIL_PASSWORD
}