Yes, there are strict restrictions when it comes to advertising on YouTube.
Firstly, your music must not contain any explicit lyrics. A radio edit/clean version is fine.
Secondly, your video should not contain any sexualised scenes. No unnecessary showing of flesh, twerking/gyrating and overt making out.
Thirdly, your video cannot contain any violence, gore, and imagery of drugs.
Learn more about Google's ad policies here.
And if you're wondering why you see movie trailers containing the above violations being advertised on YouTube all the time, it's because the movie studios spend tens of millions of dollars per year advertising on Google's web properties. They have massive financial leverage, while our most expensive package is considered pocket change to them.