spotify/helios — pull request #162 by rculbertson (2014-09-03 23:03:38+00:00)
Title: rculbertson/fix-build

Don't attach debs as maven artifacts

By default, jdeb attaches all generated debs as artifacts. We don't want to do this because it causes intermittent failures when deploying to sonatype using the nexus-staging plugin.

The helios-services module generates 3 debs - master, agent and services. Because jdeb doesn't handle multiple artifacts very well, when they get installed (via the maven-install-plugin) they all get named helios-services_.deb, each being overwritten by the next one. The gpg plugin generates signatures for all 3 debs, which are also treated as artifacts and get installed along with the debs. When the signature files get installed, their names get changed just like the debs, so they all get named helios-services_.deb.asc. But unlike the debs, the asc files may not overwrite each other, so you can end up with a signature file which was generated for a different deb. And this causes the deployment to sonatype to fail with an "invalid signature" error.

Also, attaching them as artifacts is a bit wasteful, because it means we upload ~15MB of debs to sonatype even though they will never be used. And if you run mvn install locally, they get copied into your local maven repository, but again they will never be used.