I think I found the problem. I think it misbehaved because of an illegal character in the "HOSTNAME". Changed the hostname yesterday and It was still alive this morning even if I have not pinged it.
"The counts of the indictment are luxury, bad manners, contempt for authority, disrespect to elders, and a love for chatter in place of exercise. …
Children began to be the tyrants, not the slaves, of their households. They no longer rose from their seats when an elder entered the room; they contradicted their parents, chattered before company, gobbled up the dainties at table, and committed various offences against Hellenic tastes, such as crossing their legs. They tyrannised over the paidagogoi and schoolmasters.”
@michlb1982
A couple of things, you put the device to sleep so while it's asleep, it won't respond to the commands to change the relays. Since you are combining relays and sensors, you need to keep the unit awake and find a different way to send the sensor data occasionally. For the relay status, read the comments in the sketch. You are saving the relay state and then reading that on startup. You can eliminate all of that code and just set the relay to off in the setup section.
Cheers
Al