coldframe painting

Is it safe to paint a cold frame for growing vegetables? Or is it better to just paint the outside of the wood to make it last longer? thanks…