Add apt-get update and su -c

For cloud installs apt-get update needs to be ran before we install git,
build-essentials, etc.

Change certain programs to run with sudo -c so the commands are ran with
a correct user

Change-Id: Ide4aaa433eace00bdcccfbfc7fe03493069f91eb