Redundancy is the key. Lets have two very basic options
Mining Drone Mines materials for the colony x1
Construction Drone builds buildings for the colony x1
Repair Drone Fixes the drones if they encounter faults x1
Water... erm... creation drone creates and recovers water for the drones and other processes to use x1
Biofuel Farming Drone farms and cultures biofuel to run the drones x1
With this option each is only capable of it's own specific function, and also capable of keeping the basics for continued operation going, if any of the drones fail, then the system will struggle, but if the repair drone fails then nothing can perform repairs and therefore when each drone fails over time then they will stay failed and everything else fails along with it.
Mining Drone Mines materials for the colony x2
Construction Drone builds buildings for the colony x2
Repair Drone Fixes the drones if they encounter faults x2
Water creation drone creates and recovers water for the drones and other processes to use x2
Biofuel Farming Drone farms and cultures biofuel to run the drones x2
This system is identical to the first but has redundancy, if each each drone is normally running at say 50% of its ability to provide the colony with that function, then in the event of its partner failure, then it can run at 100% for a time to allow the colony to continue at standard efficiency. in that down time the repair drone can fix the faulty one and then be back to normal, if a repair drone fails, then the other one can fix it.
Short of a massive failure or accident that takes out multiple drones then there's no reason, providing they were built well in the first place, that this system could not last until the resources completely ran out.