Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for serverless NEGs to ILB L7 module #983

Merged
merged 6 commits into from
Nov 16, 2022

Conversation

ludoo
Copy link
Collaborator

@ludoo ludoo commented Nov 16, 2022

ILB L7 only supports Cloud Run at the moment, but it will be fairly easy to add support for other serverless NEG types in the future.

PSC NEGs support is also made simple by this change, it will be added in a future PR.

This change also re-enables the forwarding rule output, which was mistakenly commented out in the refactor (thanks Daniel for pointing this out).

Serverless NEG example from the README:

module "ilb-l7" {
  source     = "./fabric/modules/net-ilb-l7"
  name       = "ilb-test"
  project_id = var.project_id
  region     = "europe-west1"
  backend_service_configs = {
    default = {
      backends = [{
        balancing_mode = "RATE"
        group = "my-neg"
        max_rate       = { per_endpoint = 1 }
      }]
    }
  }
  neg_configs = {
    my-neg = {
      cloudrun = {
        region = "europe-west1"
        target_service = {
          name = "my-run-service"
        }
      }
    }
  }
  vpc_config = {
    network    = var.vpc.self_link
    subnetwork = var.subnet.self_link
  }
}

@ludoo ludoo added incompatible change Pull request that breaks compatibility with previous version on:modules labels Nov 16, 2022
@ludoo ludoo enabled auto-merge (squash) November 16, 2022 10:08
@ludoo ludoo disabled auto-merge November 16, 2022 13:13
@ludoo ludoo merged commit 5f710f2 into master Nov 16, 2022
@ludoo ludoo deleted the ludo/net-ilb-l7-serverless branch November 16, 2022 13:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
incompatible change Pull request that breaks compatibility with previous version on:modules
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant