krobertson / deb-s3

Easily create and manage an APT repository on S3 -- NO LONGER MAINTAINED
MIT License
482 stars 148 forks source link

Despite specifying arch type ALL manifests get uploaded #96

Open jjshoe opened 8 years ago

jjshoe commented 8 years ago
$ ./bin/deb-s3 upload -a amd64 -p -b joel-test-xyz -v private joel_2-1_amd64.deb 
>> Retrieving existing manifests
>> Examining package file joel_2-1_amd64.deb
/usr/bin/dpkg
>> Uploading packages and new manifests to S3
   -- Transferring pool/j/jo/joel_2-1_amd64.deb
   -- Transferring dists/stable/main/binary-amd64/Packages
   -- Transferring dists/stable/main/binary-amd64/Packages.gz
   -- Transferring dists/stable/main/binary-i386/Packages
   -- Transferring dists/stable/main/binary-i386/Packages.gz
   -- Transferring dists/stable/Release
>> Update complete.
jjshoe commented 8 years ago

I tried wrapping https://github.com/krobertson/deb-s3/blob/master/lib/deb/s3/cli.rb#L226 in a:

if manifest.packages_to_be_upload.count > 0
...
end

But this broke uploading an arch type with any.

jjshoe commented 8 years ago

Ok, I can confirm this, wrote to a brand new bucket to ensure it's not a caching issue.

https://github.com/krobertson/deb-s3/blob/master/lib/deb/s3/release.rb#L88

The call to validate_others trips the writing out of a manifest to i386 and amd64 every time.