Coder Social home page Coder Social logo

instance template module: attempt to use `subnetwork_project` variabe fails with API error for not supported cross-project reference about terraform-google-vm HOT 6 CLOSED

terraform-google-modules avatar terraform-google-modules commented on June 5, 2024
instance template module: attempt to use `subnetwork_project` variabe fails with API error for not supported cross-project reference

from terraform-google-vm.

Comments (6)

ocervell avatar ocervell commented on June 5, 2024

I'm running into this, and it is an issue for creating instance templates for MIG that will bind to a shared VPC.

Any updates on this ? Do we know if the issue is in the API, Google provider, or Terraform module ?

from terraform-google-vm.

morgante avatar morgante commented on June 5, 2024

Haven't tested it recently, but #52 might have fixed it. Can you dive in and take a look?

from terraform-google-vm.

aaron-lane avatar aaron-lane commented on June 5, 2024

@ocervell can you verify if this was fixed by #52?

from terraform-google-vm.

DDOlafGrote avatar DDOlafGrote commented on June 5, 2024

@aaron-lane It seems that the bug still exists. Do you have an idea or a current state of this bug?

We received the following error after terraform apply:

google_compute_instance_template.appserver: Creating... Error: Error creating instance template: googleapi: Error 400: Invalid value for field 'resource.properties.networkInterfaces[0].subnetwork': 'projects/shared-vpc/regions/europe-west4/subnetworks/subnet-name-xxx'. Cross-project references for this resource are not allowed., invalid

We use the following provider versions:

provider "google" {
  region  = var.gcp_region
  project = var.gcp_project_id
  version = "= 3.15.0"
}
provider "google-beta" {
  region  = var.gcp_region
  project = var.gcp_project_id
  version = "= 3.15.0"
}
terraform {
  required_version = "= 0.12.23"
  ....
}

from terraform-google-vm.

aaron-lane avatar aaron-lane commented on June 5, 2024

@DDOlafGrote unfortunately I no longer maintain this module.

from terraform-google-vm.

DDOlafGrote avatar DDOlafGrote commented on June 5, 2024

@aaron-lane Thx for your feedback. For your information: I solved the problem by increasing the Google provider to 3.24.0.

From my perspective, this issue will be fixed by Google provider 3.24.0.

provider "google" {
  region  = var.gcp_region
  project = var.gcp_project_id
  version = "= 3.24.0"
}
 
provider "google-beta" {
  region  = var.gcp_region
  project = var.gcp_project_id
  version = "= 3.24.0"
}

from terraform-google-vm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.