terraform-provider-postgresql icon indicating copy to clipboard operation
terraform-provider-postgresql copied to clipboard

Add support for postgres stored procedures

Open AndrewJackson2020 opened this issue 1 year ago • 2 comments

This PR adds support for stored procedures in the provider. Since stored procedures are very similar to functions i based much of this implementation off of the preexisting code for functions.

Also I changed the shebang in some of the bash files so that it works on operating systems where bash is not located at /bin/bash (NixOS for example). I think this should not cause issues on operating systems where bash is located there but if it does cause any issues I am happy to revert that.

Please let me know if you see any issues and I will be happy to fix.

AndrewJackson2020 avatar May 20 '24 19:05 AndrewJackson2020

I’ve tested this by creating, updating, and deleting procedures, and it worked perfectly! Thanks @AndrewJackson2020 !

@cyrilgdn , it would be fantastic if the provider could support stored procedures like it supports functions.

rubentsirunyan avatar Aug 21 '24 11:08 rubentsirunyan

Yeah I mean it's fully unit tested so I would expect it to work, might be some edge cases that I missed though. Would be more than happy to document as well if there was any interest in merging. Unfortunately there has not been any commits to this project in around 6 months so I'm not super hopeful.

AndrewJackson2020 avatar Aug 21 '24 11:08 AndrewJackson2020