The sun plays a role in the temperature of the earth, but not to such a long term extent.
If you want to be pedantic the Sun plays the largest role in the temperature of the earth. What it may not play as large a role in is the variation of that temperature. No Sun and we have no warming at all
