[Deployment] Separate package upload portions of run-build-packages.sh to a separate script
The old way: we had a single shell script, run-build-packages.sh, that built .debs from our source repository, and uploaded them to an apt repository.
The new way: run-build-packages.sh builds packages for a single target distribution. Jenkins invokes this script multiple times in a dedicated Docker container for every distribution we support (see #6496). After that's done for every distribution, it runs the uploader script to publish the built packages.
The uploader should accept a list of distribution arguments that tell it what set(s) of packages to upload. There should be a shortcut that means "upload all known distributions." For each distribution, it should know how to find the built packages, scp them to another Web server, and run the necessary commands to publish them through an apt or yum repository.
Updated by Brett Smith over 7 years ago
I started manually testing in production, and with the latest fixups, it all works.
The first time it runs, it takes foorrrreeevvveeeerrrrr (10-15 minutes) because it uploads and publishes every .deb and .rpm we make. We can work around this by running something like
touch -d '2 weeks ago' .last_upload to set a manual cutoff point if desired. Future runs will have a timestamp and go faster.