I yelled at a CEO because he asked me to do something that wasn't related to software engineering role. He stopped asking me and anyone else in eng due to that confrontation. But - guess what - he wanted to fired every single day I worked there after that incident. I only remained because I had a lot of people protecting me.
So - you have to ask - are you willing to lose your job over it? If so - great - see ya! If not - then take your lumps and get it done.