Add GCP deployment examples: create Terraform configurations for GCP, including network setup, instance definitions, and routing, along with a README for usage instructions.

This commit is contained in:
2026-08-27 21:23:47 +02:00
parent 245d0dfd96
commit c8f54ca865
12 changed files with 465 additions and 2 deletions
+25
View File
@@ -0,0 +1,25 @@
# Bare VM on the workload subnet, for manually verifying that its traffic to
# remote_cidrs flows through the router. Off by default so a plain apply
# stays to just the router.
resource "google_compute_instance" "workload" {
count = var.deploy_workload_vm ? 1 : 0
name = "${var.name}-workload"
machine_type = var.machine_type
zone = var.zone
boot_disk {
initialize_params {
image = "ubuntu-os-cloud/ubuntu-2404-lts-amd64"
}
}
network_interface {
network = google_compute_network.internal.id
subnetwork = google_compute_subnetwork.workload.id
}
metadata = {
ssh-keys = "${var.admin_username}:${var.admin_ssh_public_key}"
}
}