headless ubuntu fsck waits for Y key during bootup

I have a headless Ubuntu 12.04 server in a datacenter 1500 miles away. Twice now on reboot the system decided it had to fsck. Unfortunately Ubuntu ran fsck in interactive mode, so I had to ask someone at my datacenter to go over, plug in a console, and press the Y key. How do I set it up so that fsck runs in non-interactive mode at boot time with the -y or -p (aka -a) flag?

For Ubuntu 15,16,17+ the FSCKFIX value setting is located in /lib/init/vars.sh

sudo nano /lib/init/vars.sh

change FSCKFIX=no to FSCKFIX=yes