The produce of the Land of Israel is a direct response to the behavior of its inhabitants. Hashem (God) makes this point very clear in the Bible, specifically in Deuteronomy, in which He links the concept of reward and punishment with the successful produce of the land. If the Children of Israel veer from God's path and turn to idolatry, Divine anger will arise and the land of Israel will fail to yield produce. This Divine reaction is actually a blessing, since the inhabitants of the Land of Israel are granted a barometer for their spiritual behavior. If there is famine and drought, they know that Hashem is angry, and they must inspect their actions. If there is plenty, God is happy with His nation and will continue to bless the land.