Skip to content

A module for OpenTofu that deploys crossfiresyncrun to GCP Cloud Run, along with configuring essential services including Firestore and Pub/Sub.

License

Notifications You must be signed in to change notification settings

UnitVectorY-Labs/crossfiresyncrun-tofu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

License Work In Progress

crossfiresyncrun-tofu

A module for OpenTofu that deploys crossfiresyncrun to GCP Cloud Run, along with configuring essential services including Firestore and Pub/Sub.

References

  • crossfiresync - A Java library enabling real-time synchronization between GCP Firestore instances across regions using Pub/Sub.
  • crossfiresyncrun - Provides real-time synchronization between GCP Firestore instances across regions using Pub/Sub, packaged as a Docker image for deployment on Cloud Run.
  • crossfiresyncrun-tofu - A module for OpenTofu that deploys crossfiresyncrun to GCP Cloud Run, along with configuring essential services including Firestore and Pub/Sub.
  • crossfiresync-firestore - Reference implementation of a crossfiresync Firestore publisher, featuring Java code and deployment scripts for Cloud Functions.
  • crossfiresync-pubsub - Reference implementation of a crossfiresync Pub/Sub consumer, featuring Java code and deployment scripts for Cloud Functions.

Usage

The basic use of this module is as follows:

module "crossfiresyncrun" {
    source = "git::https://github.com/UnitVectorY-Labs/crossfiresyncrun-tofu.git?ref=main"
    name = "mydb"
    project_id = var.project_id
    artifact_registry_name = "ghcr"
    regions = ["us-east1"]
}

Requirements

Name Version
terraform >= 1.0.0

Providers

Name Version
google n/a

Modules

No modules.

Resources

Name Type
google_cloud_run_service_iam_member.invoke_permission resource
google_cloud_run_v2_service.crossfiresyncrun resource
google_eventarc_trigger.firestore_trigger resource
google_firestore_database.databases resource
google_project_iam_member.eventarc_event_receiver_role resource
google_project_iam_member.firestore_writer_role resource
google_project_service.eventarc resource
google_project_service.firestore resource
google_project_service.pubsub resource
google_project_service.run resource
google_pubsub_subscription.pubsub_subscription resource
google_pubsub_topic.crossfiresyncrun_topic resource
google_pubsub_topic_iam_member.pubsub_publisher_role resource
google_service_account.cloud_run_sa resource
google_service_account.eventarc_sa resource

Inputs

Name Description Type Default Required
artifact_registry_host The name of the Artifact Registry repository string "us-docker.pkg.dev" no
artifact_registry_name The name of the Artifact Registry repository string n/a yes
artifact_registry_project_id The project to use for Artifact Registry. Will default to the project_id if not set. string null no
crossfiresyncrun_tag The tag for the crossfiresyncrun image to deploy string "dev" no
firestore_deletion_policy The deletion policy for Firestore databases string "ABANDON" no
name The name of the database string n/a yes
project_id The GCP project id string n/a yes
regions List of regions where resources will be created list(string) n/a yes

Outputs

No outputs.

About

A module for OpenTofu that deploys crossfiresyncrun to GCP Cloud Run, along with configuring essential services including Firestore and Pub/Sub.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages