Is it good to use terraform for invoking Lambda or serverless is the better solution?
Terraform should deal with declaring and provisioning your required infrastructure only. You can invoke Lambda functions in terraform to fetch data from that lambda function to use in your terraform modules however but it shouldn't be done to perform actions that may change infrastructure or data unknowingly.
If you need to call your lambda functions for another reason it might be good to use something like Ansible to script this action and call this as a separate step in your pipeline.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Terraform should deal with declaring and provisioning your required infrastructure only. You can invoke Lambda functions in terraform to fetch data from that lambda function to use in your terraform modules however but it shouldn't be done to perform actions that may change infrastructure or data unknowingly.
If you need to call your lambda functions for another reason it might be good to use something like Ansible to script this action and call this as a separate step in your pipeline.