mirror of
https://github.com/roleypoly/roleypoly.git
synced 2025-06-14 16:49:10 +00:00
more ci/cd work, build worker and publish
This commit is contained in:
parent
0b769913fb
commit
95a5732457
5 changed files with 185 additions and 9 deletions
|
@ -26,6 +26,10 @@ terraform {
|
|||
source = "hashicorp/null"
|
||||
}
|
||||
}
|
||||
|
||||
backend "gcs" {
|
||||
bucket = "roleypoly-tfstate"
|
||||
}
|
||||
}
|
||||
|
||||
variable "cloudflare_email" {
|
||||
|
|
|
@ -40,6 +40,12 @@ variable "api_public_uri" {
|
|||
description = "API Public Base Path"
|
||||
}
|
||||
|
||||
variable "api_path_to_worker" {
|
||||
type = string
|
||||
description = "Path to worker JS, relative to this file/terraform folder."
|
||||
default = "../worker/script.js"
|
||||
}
|
||||
|
||||
variable "root_users" {
|
||||
type = list(string)
|
||||
description = "Root users to use for role elevation calculations"
|
||||
|
|
|
@ -12,7 +12,7 @@ resource "cloudflare_workers_kv_namespace" "guild_data" {
|
|||
|
||||
resource "cloudflare_worker_script" "backend" {
|
||||
name = "roleypoly-backend-${var.environment_tag}"
|
||||
content = file("${path.module}/../worker/script.js")
|
||||
content = file("${path.module}/${var.api_path_to_worker}")
|
||||
|
||||
kv_namespace_binding {
|
||||
name = "KV_SESSIONS"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue