https://youtu.be/TunL0nyWpiI
Physically, the tree starts as a 6-foot 4x4 vinyl fence post, to which ten light sockets are mounted. Internally, there's a Raspberry Pi and a relay board driving the lights.

More details, including wiring diagrams and source code, at http://jeffpiazza.github.io/lighttree/.
/JEP