Specify Aptly repo according to LTS release

Specify our internal Apt mirror distribution according to
${DISTRIB_CODENAME}, which should be either `precise` or `trusty`.

Also, move the line that sources `/etc/lsb-release` to the top of the
file so that we can make use of `DISTRIB_CODENAME` anywhere in this
script.