Obedience of Allāh and His Messenger is the pillar of happiness and it revolves around it.
Shaykh al-Islām Ibnu Taymiyyah al-Ḥarrānī (رَحِمَهُ ٱللّٰهُ) said,
"And likewise the Levant (Shām: Syria, Palestine, Lebanon, Jordon) in the beginning (days) of Islām were amidst worldly and religious prosperity. Then they were afflicted by trials and tribulations and the kingdom escaped their hands. Then the hypocrites, atheists and christians were inflicted upon them due to their sins, and they overtook Bayt at-Maqdis (Jerusalem) and the grave of al-Khalīl (Ibrāhīm (عَلَيْهِ ٱلسَّلَامُ)), and they opened the structure that was over it and made it into a church. Then their (Levantine's), religion was rectified so Allah honoured them, and gave them victory over their enemies when they obeyed Allāh and His Messenger, and they followed what was revealed to them from their Lord. Therefore, obedience of Allāh and His Messenger is the pillar of happiness and it revolves around it."
Source: Majmūʾ al-Fatāwā Vol. 27 Pg. 437
Translated by Zubayr ʾAbbāsī