I do it by keeping a 'time server' running at home. An ESP32 and DS3231 to give a back-up clock run continuously and send an MQTT packet every second. The data is JSON formatted and gives hours, minutes, seconds, date, month, year, day of the week, GMT/DST and finally a 1 or 0 to indicate daytime or night. It checks for connection to NTP at start up and every few hours and syncs if necessary. The DST and daytime calculation is dynamic so it updates every day. The day/night triggers at sunrise and sunset so it needs to be programmed for your latitude and longitude.
It controls all kinds of equipment, including wall clock displays, time overlay into CCTV pictures and of course the lighting. Sounds like what you need.
Brian.