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

Two Composer Environments on a Shared VPC results in a IP Overlap Error #5914

Closed
dmcgowandmc opened this issue Mar 18, 2020 · 3 comments
Closed

Comments

@dmcgowandmc
Copy link

dmcgowandmc commented Mar 18, 2020

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request.
  • Please do not leave +1 or me too comments, they generate extra noise for issue followers and do not help prioritize the request.
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment.
  • If an issue is assigned to the modular-magician user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If an issue is assigned to a user, that user is claiming responsibility for the issue. If an issue is assigned to hashibot, a community member has claimed the issue already.

Terraform Version

alpine/terragrunt:0.12.19

* provider.google: version = "~> 3.13"
* provider.null: version = "~> 2.1"
* provider.random: version = "~> 2.2"

Affected Resource(s)

  • google_composer_environment

Terraform Configuration Files

resource "google_composer_environment" "my-composer" {
    name    = ${var.name}" 
    region  = var.location
    project = var.project_id

    #General Config
    config {
        node_count = var.node_count

        #Configuration of Actual Node
        node_config {
            zone         = "${var.location}-${var.zone}"
            machine_type = var.machine_type
            network      = var.network_self_link
            subnetwork   = var.subnet_self_link
            
            ip_allocation_policy {
                use_ip_aliases                = "true"
                cluster_secondary_range_name  = var.cluster_secondary_range_name
                services_secondary_range_name = var.services_secondary_range_name
            }

            service_account = var.service_account
        }

        #Enforce Private Environment
        private_environment_config {
            enable_private_endpoint = "true"
            master_ipv4_cidr_block  = var.master_ipv4_cidr_block
        }
    }
}

Expected Behavior

Two Composer Environments on a single shared VPC

Actual Behavior

{"ResourceType":"gcp-types/compute-v1:compute.networks.addPeering","ResourceErrorCode":"UNSUPPORTED_OPERATION","ResourceErrorMessage":"An IP range in the local network (172.31.255.0/29) overlaps with an IP range (172.31.255.0/29) in an active peer of the peer network."}


  on modules/as-cmp-composer/main.tf line 34, in resource "google_composer_environment" "sd-composer":
  34: resource "google_composer_environment"

Steps to Reproduce

  1. terraform apply

Important Factoids

A bit of context about this error. I'm suspecting the answer is too bad too sad, but wanted to run it past you all first then worst case, we at least know the answer.

I have a host project with a VPC that is shared between two service projects. In each service project, I am attempting to spin up composer environment.

By giving each composer environments their own subnets and master_ipv4_cidr_block blocks, the clusters for the two environments create successfully. However I am now getting an overlap error for 172.31.255.0/29 which I believe is just for composer and not the actual cluster.

The issue I have is I can't seem to find anywhere to customise this IP address to avoid conflicts.

Is it possible to customise this value?

References

b/299442858

@ghost ghost added the bug label Mar 18, 2020
@danawillow
Copy link
Contributor

@venkykuberan looks like this never got bug triaged, could you look at it?

modular-magician added a commit to modular-magician/terraform-provider-google that referenced this issue May 6, 2022
modular-magician added a commit that referenced this issue May 6, 2022
@github-actions github-actions bot added service/composer forward/review In review; remove label to forward labels Aug 17, 2023
@ScottSuarez ScottSuarez removed the forward/review In review; remove label to forward label Aug 25, 2023
@michalmodras
Copy link

This concerned Composer 1, which is in maintenance mode and new versions are not being released (https://cloud.google.com/composer/docs/composer-versioning-overview#major-versions) - please close this ticket.

@roaks3 roaks3 closed this as completed Oct 13, 2023
Copy link

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 13, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

7 participants