Keep your thumb centered on the back of the neck and under the second finger for as long as possible. When you shift to the shoulder keep the thumb in the crook of the cello even if that means it is under the first finger or further. When you need to go into thumb position, keep your left elbow and wrist high so your fingers and thumb can be on top of the fingerboard. The thumb should sit across two strings.
I think of my thumb to be as relaxed as possible when playing and especially when shifting. Allowing there to be a line going up the back of the neck and onto the fingerboard when going higher keeps the fingers moving smoothly. The thumb should not be separate from your hand frame and should move at the same time as the rest of your fingers. This is called blocking.