Startup script should run after network is online

Should fix flaky startup scripts on systemd.
Added logging when fetching metadata scripts.
Made style changes according to google's bash style guide.