88 lines
2.2 KiB
HCL
88 lines
2.2 KiB
HCL
|
|
# Select hosting option based on variable
|
|
module "hosting" {
|
|
source = "./modules/cloud_run"
|
|
|
|
# Common variables
|
|
app_name = "rothbard-portal"
|
|
gcp_project_id = var.gcp_project_id
|
|
gcp_region = var.gcp_region
|
|
firebase_project_id = google_firebase_project.default.project
|
|
flask_secret_key = var.flask_secret_key
|
|
service_account_email = google_service_account.flask_app.email
|
|
service_account_key_data = var.service_account_key_data
|
|
|
|
# Filevine credentials
|
|
filevine_client_id = var.filevine_client_id
|
|
filevine_client_secret = var.filevine_client_secret
|
|
filevine_pat = var.filevine_pat
|
|
filevine_org_id = var.filevine_org_id
|
|
filevine_user_id = var.filevine_user_id
|
|
|
|
# Module-specific variables
|
|
container_image = var.container_image
|
|
}
|
|
|
|
# Additional variables for hosting options
|
|
variable "flask_secret_key" {
|
|
description = "Flask secret key"
|
|
type = string
|
|
sensitive = true
|
|
}
|
|
|
|
variable "service_account_key_data" {
|
|
description = "Service account key JSON data"
|
|
type = string
|
|
sensitive = true
|
|
}
|
|
|
|
variable "container_image" {
|
|
description = "Docker image for Cloud Run deployment"
|
|
type = string
|
|
default = "gcr.io/your-project/rothbard-portal:latest"
|
|
}
|
|
|
|
variable "app_source_zip_path" {
|
|
description = "Path to App Engine source zip"
|
|
type = string
|
|
default = "./app-source.zip"
|
|
}
|
|
|
|
|
|
# Filevine credentials
|
|
variable "filevine_client_id" {
|
|
description = "Filevine client ID"
|
|
type = string
|
|
sensitive = true
|
|
}
|
|
|
|
variable "filevine_client_secret" {
|
|
description = "Filevine client secret"
|
|
type = string
|
|
sensitive = true
|
|
}
|
|
|
|
variable "filevine_pat" {
|
|
description = "Filevine personal access token"
|
|
type = string
|
|
sensitive = true
|
|
}
|
|
|
|
variable "filevine_org_id" {
|
|
description = "Filevine organization ID"
|
|
type = string
|
|
sensitive = true
|
|
}
|
|
|
|
variable "filevine_user_id" {
|
|
description = "Filevine user ID"
|
|
type = string
|
|
sensitive = true
|
|
}
|
|
|
|
# Output hosting-specific URLs
|
|
output "application_url" {
|
|
description = "URL of the deployed application"
|
|
value = module.hosting.service_url
|
|
}
|