An automated underground irrigation system which includes:
(a) a rain sensor or a soil moisture sensor;
(b) a flow sensor for leak detection; and
(c) a master valve to secure the system if a leak is detected.