In Christianity for example, some people argue that you should be good on this Earth in order to get your reward in heaven.
In Judaism as there is no heaven, what is the reason given to follow the commandments of Moses? Is the idea that God will strike people down like in Sodom and Gomorrah?
i.e. Is the reason to follow the commandments of Moses the threat of retribution by God in this world rather than in an afterlife? What then is thought to happen to people who comit crimes in secret and die of old age?