Deuteronomy 28:47
Because thou servedst not the LORD thy God with joyfulness, and with gladness of heart, for the abundance of all things; Because thou servedst not the LORD thy God with joyfulness, and with gladness of heart, for the abundance of all things;
The verse belongs to Moses' written account of the curses that would follow disobedience to God's law, read aloud to all the people assembled before him and set against God's promises and blessings if they would be obedient. It belongs to the law whose blessings and judgments show that God sends prosperity or adversity according to obedience or transgression, and the ark containing that law was a sacred chest, not a god or a source of power apart from obedience to God. God's promises to Israel of present and eternal good were conditional on obedience, which explains why the adult generation that left Egypt was refused entrance into the promised land.
The verse makes serving the Lord with joyfulness and gladness of heart, wholeheartedly and gratefully for the abundance of all temporal and spiritual blessings, part of that required obedience, including public acknowledgment of God's goodness, so that failure to do so is disobedience, unthankfulness, and unholiness. It states the principles of the law of God's kingdom plainly and specifically so minds are not left in ignorance and uncertainty, laying a never-ceasing obligation on all whom God has blessed with life and health and temporal and spiritual advantages. Its claims are just as binding now and just as fresh in importance as God's gifts are fresh and continual, and its message has not grown weak because of age.
Failure to serve God joyfully displeases Him and dishonors His name and brings curse and judgment, and it will not go unreproved or unpunished, because He will not allow the people He has separated from the world to dishonor Him and will not give His own glory to another. Read carefully with Exodus 15, the chapter is God's message of encouragement and instruction that diligently hearkening to His voice and keeping His commandments and statutes keeps away disease so His people may live in health and holiness and learn obedience under Christ's direction and healing power. Transgressing God's law and breaking down the barriers He erected to preserve from disease brings suffering and disease of every kind.
Such unthankful, unholy failure to serve with joy alters God's purpose toward His people, hinders the advance of His work, and prolongs time and delays the sealing while the last message of mercy is proclaimed. The verse declares that if Israel refused to keep the way of the Lord and obey His laws another power would rule over them, and that foreign domination came because Israel did not serve God. The Jews in Christ's day were still under it while expecting an earthly prince to deliver them and break their bondage.