variables.tf 1.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. # Variables for minimal GCP Cloud Run deployment
  2. variable "project_id" {
  3. description = "GCP Project ID"
  4. type = string
  5. }
  6. variable "region" {
  7. description = "GCP region for deployment"
  8. type = string
  9. default = "us-central1"
  10. }
  11. variable "project_name" {
  12. description = "Name of the project (used for resource naming)"
  13. type = string
  14. default = "llama-api"
  15. }
  16. variable "environment" {
  17. description = "Environment name (dev, staging, prod)"
  18. type = string
  19. default = "dev"
  20. }
  21. variable "container_image" {
  22. description = "Container image URL for the Cloud Run service"
  23. type = string
  24. default = "gcr.io/cloudrun/hello"
  25. }
  26. variable "cpu_limit" {
  27. description = "CPU limit for the container"
  28. type = string
  29. default = "2"
  30. }
  31. variable "memory_limit" {
  32. description = "Memory limit for the container"
  33. type = string
  34. default = "2Gi"
  35. }
  36. variable "container_port" {
  37. description = "Port that the container listens on"
  38. type = number
  39. default = 8080
  40. }
  41. variable "min_instances" {
  42. description = "Minimum number of instances"
  43. type = number
  44. default = 0
  45. }
  46. variable "max_instances" {
  47. description = "Maximum number of instances"
  48. type = number
  49. default = 10
  50. }
  51. variable "execution_environment" {
  52. description = "Execution environment for the service"
  53. type = string
  54. default = "EXECUTION_ENVIRONMENT_GEN2"
  55. }
  56. variable "environment_variables" {
  57. description = "Environment variables for the container"
  58. type = map(string)
  59. default = {}
  60. }
  61. variable "allow_public_access" {
  62. description = "Whether to allow public access to the service"
  63. type = bool
  64. default = false
  65. }
  66. variable "allowed_members" {
  67. description = "List of members allowed to access the service"
  68. type = list(string)
  69. default = []
  70. }