Srimad Bhagavatam Canto 10, Chapter 54, Text 12

SB 10.54.12

yatha daru-mayi yosit
 nrtyate kuhakecchaya
evam isvara-tantro ’yam
 ihate sukha-duhkhayoh
 
Translation: 
 
Just as a puppet in the form of a woman dances by the desire of the puppeteer, so this world, controlled by the Supreme Lord, struggles in both happiness and misery.
 
Purport: 
 
By the will of the Supreme Lord, living beings are awarded the proper results of their own activities. One who understands the Absolute Truth surrenders to the Absolute Truth, the Supreme Personality of Godhead, and is no longer considered to be within the material system of existence. Since those endeavoring within the material system, or world, are necessarily trying to exploit the creation of God, they must be subjected to reactions, which are perceived by the conditioned souls as miserable and joyful. In fact, the entire material way of life is a fiasco when seen from the perspective of absolute bliss.
Srimad Bhagavatam Canto 10, Chapter 54, Text 11
Srimad Bhagavatam Canto 10, Chapter 54, Text 13