mirror of
https://github.com/whekin/household-bot.git
synced 2026-03-31 22:54:02 +00:00
feat(bot): add /dashboard command and MINI_APP_URL config
- Add /dashboard command to BotFather registration alongside /app - Add new MINI_APP_URL env var for dashboard URL (separate from CORS origins) - Pass MINI_APP_URL and BOT_API_URL in CD workflow - Update Terraform with new variable for future infrastructure deployments
This commit is contained in:
@@ -166,6 +166,9 @@ module "bot_api_service" {
|
||||
length(var.bot_mini_app_allowed_origins) == 0 ? {} : {
|
||||
MINI_APP_ALLOWED_ORIGINS = join(",", var.bot_mini_app_allowed_origins)
|
||||
},
|
||||
var.bot_mini_app_url == null ? {} : {
|
||||
MINI_APP_URL = var.bot_mini_app_url
|
||||
},
|
||||
{
|
||||
SCHEDULER_OIDC_ALLOWED_EMAILS = google_service_account.scheduler_invoker.email
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@ bot_assistant_rate_limit_burst = 5
|
||||
bot_assistant_rate_limit_burst_window_ms = 60000
|
||||
bot_assistant_rate_limit_rolling = 50
|
||||
bot_assistant_rate_limit_rolling_window_ms = 86400000
|
||||
bot_mini_app_url = "https://household-dev-mini-app-abc123-ew.a.run.app"
|
||||
bot_mini_app_allowed_origins = [
|
||||
"https://household-dev-mini-app-abc123-ew.a.run.app"
|
||||
]
|
||||
|
||||
@@ -139,6 +139,13 @@ variable "bot_assistant_rate_limit_rolling_window_ms" {
|
||||
nullable = true
|
||||
}
|
||||
|
||||
variable "bot_mini_app_url" {
|
||||
description = "Optional URL for /app and /dashboard bot commands"
|
||||
type = string
|
||||
default = null
|
||||
nullable = true
|
||||
}
|
||||
|
||||
variable "bot_mini_app_allowed_origins" {
|
||||
description = "Optional allow-list of mini app origins for bot CORS handling"
|
||||
type = list(string)
|
||||
|
||||
Reference in New Issue
Block a user