layman: hard-coded fetching from gentoo.org and broken overlays when an 'add' is interrupted
Hi all. Some questions rgd layman:
1. Seems like layman is hard-wired to contain the layman-global.txt
list of overlays. What's the reasoning behind this? My issue
w/this is that, lately, when gentoo.org was unreachable, this
hard-wiring presented considerable hangs on fetch attempts.
2. Layman refuses to overwrite an existing local overlay dir, if that
dir already exists. I've experienced the following scenario:
1. added an overlay and broke layman w/ctrl+C before it finished.
2. attempted to re-execute the add action. Layman refuses,
saying it will not overwrite the dir.
3. attempted to remove overlay w/-d. Layman refuses, saying
there's no such overlay.
4. Same refusal (obviously) when attempting to sync the
incomplete overlay.
I think layman should allow the overwrite, at least pending a (-f)orce
flag. As far as my use-cases go, the local instance of the overlay has
no importance: it's just a copy from some overlay repo.
Would appreciate comments,
Amit
04-21-2010, 09:33 PM
"Robin H. Johnson"
layman: hard-coded fetching from gentoo.org and broken overlays when an 'add' is interrupted
On Thu, Apr 22, 2010 at 12:09:21AM +0300, Amit Dor-Shifer wrote:
> Hi all. Some questions rgd layman:
>
> 1. Seems like layman is hard-wired to contain the layman-global.txt
> list of overlays. What's the reasoning behind this? My issue
> w/this is that, lately, when gentoo.org was unreachable, this
> hard-wiring presented considerable hangs on fetch attempts.
It's definitely NOT hardcoded.
# grep www.gentoo.org /etc/layman/layman.cfg
overlays : http://www.gentoo.org/proj/en/overlays/repositories.xml
--
Robin Hugh Johnson
Gentoo Linux: Developer, Trustee & Infrastructure Lead
E-Mail : robbat2@gentoo.org
GnuPG FP : 11AC BA4F 4778 E3F6 E4ED F38E B27B 944E 3488 4E85
04-21-2010, 10:05 PM
Amit Dor-Shifer
layman: hard-coded fetching from gentoo.org and broken overlays when an 'add' is interrupted
Robin H. Johnson wrote:
On Thu, Apr 22, 2010 at 12:09:21AM +0300, Amit Dor-Shifer wrote:
Hi all. Some questions rgd layman:
1. Seems like layman is hard-wired to contain the layman-global.txt
list of overlays. What's the reasoning behind this? My issue
w/this is that, lately, when gentoo.org was unreachable, this
hard-wiring presented considerable hangs on fetch attempts.
When I invoke the following, I see http interaction w/gentoo.org:
layman -c /dev/null -N -f -a oversi -o file:///tmp/layman-oversi.xml
which AFAIK doesn't read /etc/layman/layman.cfg.
http interaction indicated by running 'tshark host www.gentoo.org' while
executing the above.
Amit
04-22-2010, 02:32 AM
"Robin H. Johnson"
layman: hard-coded fetching from gentoo.org and broken overlays when an 'add' is interrupted
On Thu, Apr 22, 2010 at 01:05:11AM +0300, Amit Dor-Shifer wrote:
> When I invoke the following, I see http interaction w/gentoo.org:
>
> layman -c /dev/null -N -f -a oversi -o file:///tmp/layman-oversi.xml
> which AFAIK doesn't read /etc/layman/layman.cfg.
The config file given (empty via /dev/null in this case) overrides the
options from self.defaults. Using '-c /dev/null' imports an EMPTY
config, and empty does NOT override anything, leaving you with the
defaults.
Do this instead:
# cat >/etc/layman/empty-overlays.xml <<EOF
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE repositories SYSTEM "/dtd/repositories.dtd">
<repositories xmlns="" version="1.0" />
EOF
Then set the 'overlays' key as:
overlays: file:///etc/layman/empty-overlays.xml
Or better yet, just put your OWN layman-oversi.xml reference into there
and distribute that file, and avoid the entire need for the -o argument.
--
Robin Hugh Johnson
Gentoo Linux: Developer, Trustee & Infrastructure Lead
E-Mail : robbat2@gentoo.org
GnuPG FP : 11AC BA4F 4778 E3F6 E4ED F38E B27B 944E 3488 4E85
04-22-2010, 07:06 AM
Amit Dor-Shifer
layman: hard-coded fetching from gentoo.org and broken overlays when an 'add' is interrupted
Robin H. Johnson wrote:
On Thu, Apr 22, 2010 at 01:05:11AM +0300, Amit Dor-Shifer wrote:
When I invoke the following, I see http interaction w/gentoo.org:
layman -c /dev/null -N -f -a oversi -o file:///tmp/layman-oversi.xml
which AFAIK doesn't read /etc/layman/layman.cfg.
The config file given (empty via /dev/null in this case) overrides the
options from self.defaults. Using '-c /dev/null' imports an EMPTY
config, and empty does NOT override anything, leaving you with the
defaults.
Do this instead:
# cat >/etc/layman/empty-overlays.xml <<EOF
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE repositories SYSTEM "/dtd/repositories.dtd">
<repositories xmlns="" version="1.0" />
EOF
Then set the 'overlays' key as:
overlays: file:///etc/layman/empty-overlays.xml
Or better yet, just put your OWN layman-oversi.xml reference into there
and distribute that file, and avoid the entire need for the -o argument.
ok. Thanks. I'll try generating a layman.cfg on the fly, read it w/(-c)
and reference my overlay index from there. I want to ignore
/etc/layman/layman.cfg