-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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 API Gateway Resources #7212
Add API Gateway Resources #7212
Comments
Most of the commands to manipulate the cloud gateway seem fairly straightforward. The resources are easy to reference and are unique. The challenge / design decision seems to be mostly based around how to handle the openapi specification yaml file. Is that something that would be embedded into a terraform config / module or would it simply be referenced and edited along side |
I'd suggest keeping it simple in the beginning, using a regular string field, like so: openapi_documents = [yamlencode({
swagger = "2.0"
…
})] This is similar to how it can be done, for example, through the |
I'm thinking of having a yaml template that terraform dynamically generates at plan/apply time. As you see in the tutorials you need to supply urls of functions and cloud run services. Maybe some service account emails too. https://www.terraform.io/docs/configuration/functions/templatefile.html |
For sure, and the above syntax ( |
OK so I dug into what it takes to write these. There's a generator written in ruby that probably needs to be used. It would take me awhile to wrap my head around how that works. I'd appreciate some guidance from the team on the best example resource that's similar to this so I can get an example before digging in. FWIW it's fairly impressive. |
You could also have a look at https://github.com/GoogleCloudPlatform/magic-modules/tree/master/products/servicemanagement which is the config for Google Cloud Endpoints which is a very similar product to the new API Gateway product |
FYI: I already wrote a PR for this. It is the linked issue that will close this issue. |
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 feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks! |
Community Note
Description
Google released the API Gateway.
https://cloud.google.com/blog/products/serverless/google-cloud-api-gateway-is-now-available-in-public-beta
https://cloud.google.com/api-gateway/docs/reference/rest/v1beta/projects.locations.gateways
New or Affected Resource(s)
Potential Terraform Configuration
References
The text was updated successfully, but these errors were encountered: