Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 63837 - torpage (new ebuild)
Summary: torpage (new ebuild)
Status: RESOLVED WONTFIX
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal normal with 1 vote (vote)
Assignee: Default Assignee for New Packages
URL:
Whiteboard: sunrise suggested
Keywords: EBUILD
Depends on:
Blocks:
 
Reported: 2004-09-12 15:28 UTC by Jaco Kroon
Modified: 2019-12-07 11:49 UTC (History)
5 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
ebuild for torpage-0.1 (torpage-0.1.ebuild,704 bytes, text/plain)
2004-09-12 15:40 UTC, Jaco Kroon
Details
Updated patch for torpage 0.1.2 instead (torpage-0.1.2.ebuild,725 bytes, text/plain)
2004-09-23 13:13 UTC, Jaco Kroon
Details
torpage-0.1.3 (torpage-0.1.3.ebuild,730 bytes, text/plain)
2004-12-01 21:29 UTC, Jaco Kroon
Details
ebuild for torpage-0.2.0 (torpage-0.2.0.ebuild,776 bytes, text/plain)
2005-03-28 06:59 UTC, Jaco Kroon
Details
ebuild for torpage-0.2.1 (torpage-0.2.1.ebuild,800 bytes, text/plain)
2005-03-31 14:35 UTC, Jaco Kroon
Details
torpage-0.2.2 (torpage-0.2.2.ebuild,800 bytes, text/plain)
2005-04-14 13:27 UTC, Jaco Kroon
Details
torpage-0.2.3 ebuild (torpage-0.2.3.ebuild,800 bytes, text/plain)
2005-05-08 13:29 UTC, Jaco Kroon
Details
torpage-0.2.3.ebuild (torpage-0.2.3.ebuild,814 bytes, text/plain)
2005-12-18 23:33 UTC, Jaco Kroon
Details
torpage-0.2.4.ebuild (torpage-0.2.4.ebuild,818 bytes, text/plain)
2006-03-05 00:29 UTC, Jaco Kroon
Details
torpage-0.2.6.ebuild (torpage-0.2.6.ebuild,813 bytes, text/plain)
2007-11-22 11:51 UTC, Jaco Kroon
Details
Support FILE parameter in torpage_fetch (torpage_fetch-FILE.patch,636 bytes, patch)
2009-04-15 07:25 UTC, Krzysztof Olędzki
Details | Diff
torpage-0.2.7.ebuild (torpage-0.2.7.ebuild,813 bytes, text/plain)
2010-06-15 11:29 UTC, Jaco Kroon
Details
torpage-0.2.8 (torpage-0.2.8.ebuild,858 bytes, text/plain)
2010-12-16 17:22 UTC, Jaco Kroon
Details
Patch for torpage_server (torpage_server.patch,479 bytes, patch)
2011-01-10 10:17 UTC, jusko
Details | Diff
torpage-0.2.9.ebuild (torpage-0.2.9.ebuild,858 bytes, text/plain)
2011-03-06 11:03 UTC, Jaco Kroon
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jaco Kroon 2004-09-12 15:28:09 UTC
Torpage is a helper to portage that allows one to maintain a central server that only contains the distfiles that one actually require.  It also takes cares of problems relating to downloading the same distfiles over and over again when maintaining a large number of machines.

Torpage takes care of this, for me at least.  I'm submitting the ebuild in the hope that other people may also benifit from this work.

Reproducible: Always
Steps to Reproduce:
Comment 1 Jaco Kroon 2004-09-12 15:40:39 UTC
Created attachment 39469 [details]
ebuild for torpage-0.1
Comment 2 Jaco Kroon 2004-09-23 13:13:53 UTC
Created attachment 40243 [details]
Updated patch for torpage 0.1.2 instead

Right, a small bug fix along with various other updates (improved logging,
support for using localhost as the torpage server).

More explanations at http://www.kroon.co.za/torpage.php
Comment 3 Jaco Kroon 2004-12-01 21:29:44 UTC
Created attachment 45109 [details]
torpage-0.1.3

New ebuild, adjusts to using portage-2.0.51.
Comment 4 Jaco Kroon 2005-03-28 06:59:29 UTC
Created attachment 54670 [details]
ebuild for torpage-0.2.0

Much updated torage package.  Solves most of the issues I encountered so far,
in addition this one can run on non-gentoo systems (the server at least)
permitting the portage tree and a "distfiles" directory is available.  There is
still a few enhancements to be made, let me know what you think.
Comment 5 Jaco Kroon 2005-03-31 14:35:26 UTC
Created attachment 54974 [details]
ebuild for torpage-0.2.1
Comment 6 Jaco Kroon 2005-04-14 13:27:30 UTC
Created attachment 56292 [details]
torpage-0.2.2

Mainly enhancements to the distfiles_cleanup script.
Comment 7 Jaco Kroon 2005-05-08 13:29:43 UTC
Created attachment 58393 [details]
torpage-0.2.3 ebuild

Small bugfix where /etc/make.conf got sourced inappropriately, possibly
clobbering a PKGDIR variable.
Comment 8 Petteri Räty (RETIRED) gentoo-dev 2005-10-14 00:34:59 UTC
A couple of comments:
-LICENSE should match a license in ${PORTDIR}/licenses
-The standard ebuild header has switched to using Copyright 1999-2005 Gentoo 
 Foundation.
-the src_compile renaming should be done in src_unpack. I wonder why it is not
 renamed torpage already in the tarball?
Comment 9 Jaco Kroon 2005-12-18 23:33:47 UTC
Created attachment 75058 [details]
torpage-0.2.3.ebuild

Sorry for the time it took, should be ok now.
Comment 10 Jaco Kroon 2005-12-18 23:36:01 UTC
Oh, as for the renaming, there was work in progress to enable the server to run on other distributions as well.  Essentially it's a matter of adding appropriate startup scripts, thus the idea is to let the script-name match the distribution on which to use it.
Comment 11 Jaco Kroon 2006-03-05 00:29:15 UTC
Created attachment 81369 [details]
torpage-0.2.4.ebuild

Updated ebuild for new version, now makes use of OpenSSL to perform digesting in order to support a wider range of hashes.  There is also a not so minor security fix if you used the authentication stuff, basically you could provide any username and password.  Not sure how that slipped through.
Comment 12 Jaco Kroon 2007-11-22 11:51:24 UTC
Created attachment 136671 [details]
torpage-0.2.6.ebuild
Comment 13 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2009-01-13 20:51:48 UTC
(this is an automated message based on filtering criteria that matched this bug)

Hello, The Gentoo Team would like to firstly thank you for your ebuild
submission. We also apologize for not being able to accommodate you in a timely
manner. There are simply too many new packages.

Allow me to use this opportunity to introduce you to Gentoo Sunrise. The sunrise overlay[1] is a overlay for Gentoo which we allow trusted users to commit to and all users can have ebuilds reviewed by Gentoo devs for entry into the overlay.
So, the sunrise team is suggesting that you look into this and submit your
ebuild to the overlay where even *you* can commit to. =)

Because this is a mass message, we are also asking you to be patient with us. We anticipate a large number of requests in a short time. 

Thanks,
On behalf of the Gentoo Sunrise Team,
Jeremy.

[1]: http://www.gentoo.org/proj/en/sunrise/
[2]: http://overlays.gentoo.org/proj/sunrise/wiki/SunriseFaq
Comment 14 Krzysztof Olędzki 2009-04-15 07:22:48 UTC
Current portage emits:

!!! FETCHCOMMAND_TORPAGE does not contain the required ${FILE} parameter.
!!! RESUMECOMMAND_TORPAGE does not contain the required ${FILE} parameter.
!!! Refer to the make.conf(5) man page for information about how to
!!! correctly specify FETCHCOMMAND and RESUMECOMMAND.

It think we could simply fix "torpage_fetch" to accept three parametres and change FETCHCOMMAND_TORPAGE/RESUMECOMMAND_TORPAGE to:
FETCHCOMMAND_TORPAGE=="/usr/sbin/torpage_fetch \"\${DISTDIR}/\${FILE}\" \"\${URI}\""
RESUMECOMMAND_TORPAGE=="/usr/sbin/torpage_fetch \"\${DISTDIR}/\${FILE}\" \"\${URI}\""

Comment 15 Krzysztof Olędzki 2009-04-15 07:25:09 UTC
Created attachment 188385 [details, diff]
Support FILE parameter in torpage_fetch
Comment 16 Jaco Kroon 2010-06-15 11:29:57 UTC
Created attachment 235391 [details]
torpage-0.2.7.ebuild

New version also includes patch for the FILE parameter.  Includes a few other random fixes as per the changelog:

* Implement lockf based locking.
* torpage-lockf
* Replace the protocol determination and command determining code.
* Only check checksums on startup if we have a non-empty file.
* Update lockfile location.
* Don't stop checking checksums at first bad checksum.
* The default FETCHCOMMAND uses -O in portage now, clone to torpage.
* Take a third parameter to torpage_fetch for ${FILE}
* Make scripts executable.

The two changes that carries real effect is the locking related changes that will now co-operate properly with portage (limited testing last night) and the properly supported ${FILE} parameter.
Comment 17 Jaco Kroon 2010-12-16 17:22:12 UTC
Created attachment 257338 [details]
torpage-0.2.8

Changelog:

f0d935c Improved verbose feedback and split OK checking out of loop (solves scope problems)
4144e32 Hack to deal with ${URI} -> ${FILE} rename structures.
c57fd6b Make default fetch commands go guiet.
7fd8c11 Export CATEGORY, PN and PF for use by sub-torpage_fetch processes.
927802d Use pipefail so we can log downloader exit codes.
3e36f01 Give a full path to -O instead of messing with -P to wget.
Comment 18 jusko 2011-01-10 10:17:30 UTC
Created attachment 259452 [details, diff]
Patch for torpage_server

openssl dgst was inserting "(stdin)= " before the hashsums, causing torpage to fail. Using this patch as a quick-fix.
Comment 19 Jaco Kroon 2011-01-10 11:10:07 UTC
Never versions of ssl adds the tag.  I don't see a simpler/easier fix.  I've added the patch to my git repository thanks.  I can roll a new version if need be but I'd prefer to batch a few more changes - if it's critical for you I'll roll a 0.2.9 version?

commit f8f2e95769376ad1f04b9b26d597bb093312cb9e
Author: Jaco Kroon <jaco@uls.co.za>
Date:   Mon Jan 10 12:28:43 2011 +0200

    Newer versions of OpenSSL adds a filename tag in front of the actual checksum, just get rid of i

diff --git a/sbin/torpage_server b/sbin/torpage_server
index f0dc724..fca9bc4 100755
--- a/sbin/torpage_server
+++ b/sbin/torpage_server
@@ -167,7 +167,7 @@ function has_file() {
 
                case $DMETHOD in
                        md[245]|rmd160|mdc2|sha|sha1|sha256|sha512)
-                               local DIGEST_FETCHED_VALUE=$(/usr/bin/openssl dgst -"${DMETHOD}" < "
+                               local DIGEST_FETCHED_VALUE=$(/usr/bin/openssl dgst -"${DMETHOD}" < "
                                [[ "${DIGEST_FETCHED_VALUE}" == "${DVALUE}" ]] && chkres=0
                        ;;
                        *)

The only functional change is that I force the (stdin)= to be at the beginning of the line.

Thanks for the diff.
Comment 20 Jaco Kroon 2011-03-06 11:03:28 UTC
Created attachment 264907 [details]
torpage-0.2.9.ebuild

Incorporated patches for fixing checksum issue.
Comment 21 Jaco Kroon 2019-12-07 11:49:40 UTC
This will no longer function.  And no plans to repair.