How to check if a number is positive or negative in terraform?

You can use terraform signum() function to determine the sign of a number, it returns -1 for a negative number 1 for a positive number, and 0 for zero.

Open terraform console

Check if a number is positive or negative in terraform

Leave a Reply