A part of the plumbing code for California says:
(2) All piping and tubing shall be run as directly as practical with adequate provisions for expansion, contraction, jarring, vibration and settling. Exterior piping may be either buried or installed aboveground and shall be well supported and...