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 triggers to Cloud Functions v2 #965
Add triggers to Cloud Functions v2 #965
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple minor comments and a doubt which can be ignored, but good to go many thanks!
@juliocc @ludoo the only feature I also consider for this, is to also support creation of trigger service accounts. As you can notice in example - caller needs to specify service account for trigger by themselves. I can add The other thing that I guess we could improve here is to provide option to specify roles for Cloud Function service account. Though this kind of overlaps with |
363bb03
to
483650e
Compare
That looks like a good idea, up to you if you want to add it here or in a separate PR. Julio was also thinking about splitting the module into a v1 and a v2 module, which kind of makes sense. Again, feel free to merge this and we can discuss it later, or split it now if it makes more sense to you. BTW, you should see a merge button already, if that's not the case let us know. |
Lets's discuss it. I've been thinking about it for a few days but tbh I don't know if it's a good idea. |
* add `trigger_config_v2` for v2 functions * add optional for objects in variables.tf * make examples in README runnable * add example for Cloud Function v2 * add exapmle for trigger for Cloud Function v2 * remove optional variables from examples with `null` value
* Refactor trigger_config and trigger_config_v2 into one structure * bump default python version to 3.10 * typo fixes
6c194a0
to
0121806
Compare
trigger_config
and create substructures for v1 Cloud Functions and v2bucket_config.lifecycle_delete_age
tobucket_config,lifecycle_delete_age_days
function_config.instances
tofunction_config.instance_count
function_config.memory
tofunction_config.memory_mb
function_config.timeout
tofunction_config.timeout_seconds
null
valueCloses #973