Job 37:13 (ESV)

13 Whether for correction or for his land or for love, he causes it to happen.

It is God who decides the purpose of every cloud and rainstorm, whether he will use it to punish or to bestow care (see Job 36:31).