Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Put .deb file in root of APT repo #3202

Merged
merged 1 commit into from
Nov 18, 2020

Conversation

HebaruSan
Copy link
Member

Problem

The repo from #3197 is closer to working after #3201, but still has some issues, including this when attempting to install ckan:

Fehl:3 http://ksp-ckan.s3-us-west-2.amazonaws.com/deb nightly/main all ckan all 1.29.1                                  
404  Not Found [IP: 52.218.240.57 80]                           
E: Fehlschlag beim Holen von http://ksp-ckan.s3-us-west-2.amazonaws.com/deb/./ckan_1.29.1_all.deb 404  Not Found [IP: 52.218.240.57 80]
---
Err:3 http://ksp-ckan.s3-us-west-2.amazonaws.com/deb nightly/main all ckan all 1.29.1                                  
404  Not Found [IP: 52.218.240.57 80]                           
E: Error while fetching http://ksp-ckan.s3-us-west-2.amazonaws.com/deb/./ckan_1.29.1_all.deb 404  Not Found [IP: 52.218.240.57 80]

Cause

The deb/dists/nightly/main/binary-all/Packages.gz file contains:

Filename: ./ckan_1.29.1_all.deb

... which I thought from the documentation would be interpreted relative to that file's location to produce deb/dists/nightly/main/binary-all/./ckan_1.29.1_all.deb, similar to how web relative URLs normally work. Rather it looks like that path is appended to the root path of the repo, which is not where our .deb file currently is.

Changes

Now we put the .deb file in /deb/. To make this work, the two S3 sync commands are now:

  • Put _build/deb/apt-repo-root into /deb/, which will contain just the .deb file
  • Put _build/deb/apt-repo-dist into /deb/dists/stable/ or /deb/dists/nightly/, which will contain everything else

The Makefile is adjusted to generate those folders accordingly.

Note, there are still other issues relating to signatures and architectures. Those will be addressed in future changes and are not attempted to be solved here.

@HebaruSan HebaruSan added Bug Something is not working as intended Pull request Build Issues affecting the build system Linux Issues specific for Linux Package: deb Issues affecting the Debian packaging labels Nov 18, 2020
debian/Makefile Outdated Show resolved Hide resolved
@HebaruSan HebaruSan merged commit ca253b8 into KSP-CKAN:master Nov 18, 2020
@HebaruSan HebaruSan deleted the fix/apt-repo-deb-path branch November 18, 2020 22:48
@DasSkelett
Copy link
Member

Ugh, APT can not handle a ./ in the path correctly :/

Err:1 http://ksp-ckan.s3-us-west-2.amazonaws.com/deb nightly/main all ckan all 1.29.1
404  Not Found [IP: 52.218.160.73 80]
E: Failed to fetch http://ksp-ckan.s3-us-west-2.amazonaws.com/deb/./ckan_1.29.1_all.deb  404  Not Found [IP: 52.218.160.73 80]

@HebaruSan
Copy link
Member Author

HebaruSan commented Nov 18, 2020

🤦
Obviously it works fine in a browser (and presumably any other app or library that understands what a URL is).

@HebaruSan
Copy link
Member Author

Got frustrated and attempted a fix w/o PR: abc1606

Any improvement?

@DasSkelett
Copy link
Member

Had to fight some caching on APT's side (in /var/lib/apt/lists/), but afterwards it installed successfully 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something is not working as intended Build Issues affecting the build system Linux Issues specific for Linux Package: deb Issues affecting the Debian packaging
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants