Bug 1074194 - configurable download location for 'yumdownloader' equivalent
Summary: configurable download location for 'yumdownloader' equivalent
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: dnf-plugins-core
Version: 20
Hardware: Unspecified
OS: Unspecified
low
unspecified
Target Milestone: ---
Assignee: Tim Lauridsen
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1045679
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-03-08 19:58 UTC by Michal Jaegermann
Modified: 2014-06-02 07:47 UTC (History)
6 users (show)

Fixed In Version: 0.0.8
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-06-02 07:47:26 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Michal Jaegermann 2014-03-08 19:58:24 UTC
Description of problem:

'man dnf.conf' says the following about /etc/yum.repos.d: "The latter is  typically used for repository configuration".  If one want to use that "atypically" then what? Documentation is numb about 'reposdir' directive as present in yum.conf.  The other one which is sorely missing is 'cachedir'.  In case yumdownloader is used, for example,
to download selected packages for various distributions (and that presumes that yumdownloader utilty, or equivalent, eventually will be dnf based) those missing directives make the whole exercise rather painfull.  There are surely other scenarios when these two were used.  Over years on various systems I was changing many times 'cachedir' configuration for assorted reasons.

Version-Release number of selected component (if applicable):
dnf-0.4.17-1.fc20

Comment 1 Ales Kozumplik 2014-03-10 09:33:01 UTC
Hello, thanks for the report. This should be configurable of course.

The 'yumdownloader' bug is 1045679.

Comment 2 Michal Jaegermann 2014-03-10 13:57:39 UTC
Hm, it does not look to me that a changed subject reflects a content of the original report.  'yumdownloader' just served as an example here.  The point was that means to set "cachedir" and "reposdir" so far are missing.  The first one, for example, is routinely used by Fedora to separate old and new caches while running distro upgrades.  Hopefuly you are not planning to forget that facility.

Comment 3 Tim Lauridsen 2014-04-02 11:09:41 UTC
both cachedir & repodir is listed in the public 
http://akozumpl.github.io/dnf/api_conf.html

dnf.conf.Conf is merged with values from the /etc/dnf/dnf.conf by the dnf cli
so it don't look like they are going away.

a custom dnf.conf can be loaded with

dnf -c <path to conf file>

So it look like it is only the dnf.conf man page there are missing infomation about these options.

Comment 4 Michal Jaegermann 2014-04-02 17:29:11 UTC
(In reply to Tim Lauridsen from comment #3)
> both cachedir & repodir is listed in the public 
> http://akozumpl.github.io/dnf/api_conf.html

Indeed, although at least 'cachedir' does not specify such location (as opposed to what yum is doing) but a top directory in which dnf will build its own tree.  Likely close enough for practical purposes.   'man dnf.conf' should document that.

OTOH 'man dnf' describes "--disableexcludes=[all|main|<repoid>] ....", implying that such thing do exist but neither 'man dnf.conf' nor http://akozumpl.github.io/dnf/api_conf.html mentions anything how to provide such specification.  Does this deserve a separate bugzilla report?

Also very important in many situations '--skip-broken' options apears to be AWOL (another report?)

I did try  undocumented 'cachedir' a while ago and then it was just ignored.  I considered that WIPO and did not report problems at that time.

Comment 5 Tim Lauridsen 2014-04-03 05:30:30 UTC
> 
> Also very important in many situations '--skip-broken' options apears to be
> AWOL (another report?)

--skip-broken option don't exist in dnf, afaik dnf does always skip broken by default

Comment 6 Tim Lauridsen 2014-04-03 05:40:57 UTC
cachedir set where the dnf cache is located.

did some testing

/home/tim/dnf/dnf.conf
[main]
cachedir=/home/tim/dnf


$ sudo dnf -c /home/tim/dnf/dnf.conf makecache

will make a fresh dnf cache in /home/tim/dnf

but it seams like it is only working as root

Comment 7 Tim Lauridsen 2014-04-03 06:13:53 UTC
Sorry, to many open tabs, changed to wrong one ;-)

Comment 8 Michal Jaegermann 2014-04-03 17:06:29 UTC
(In reply to Tim Lauridsen from comment #5)

> --skip-broken option don't exist in dnf, afaik dnf does always skip broken
> by default

So it does but in a clearly deficient manner.  See bug 1084129.

Comment 9 Tim Lauridsen 2014-04-29 05:49:04 UTC
Hi Michael

Does this solve your needs
http://dnf-utils.readthedocs.org/en/latest/command-ref.html#dnl-command


Use these command to test the tool:

sudo dnf copr enable timlau/dnf-utils
sudo dnf install dnf-utils

The plan is move the tool into dnf-plugins-core when ready

Comment 10 Michal Jaegermann 2014-04-29 21:21:53 UTC
(In reply to Tim Lauridsen from comment #9)

> Does this solve your needs

Hard to tell.  Maybe.


> Use these command to test the tool:
> 
> sudo dnf copr enable timlau/dnf-utils

A response to that is:

No such command: copr. Please use /usr/bin/dnf --help

Well, indeed, neither 'man dnf' nor 'dnf --help' mentions anything of that sort.  The same actually applies to "enable" in this context.

The general issue seems to be that 'man dnf' says "It roughly maintains  CLI  compatibility with Yum" where what "roughly" may eventually mean is anybodys guess.  At this stage I am not that interested in dnf.

Comment 11 Tim Lauridsen 2014-04-30 05:35:19 UTC
you need to do a

sudo dnf install dnf-plugins-core

to get access to the copr command

Comment 12 Ales Kozumplik 2014-04-30 05:46:41 UTC
(In reply to Michal Jaegermann from comment #10)
> The general issue seems to be that 'man dnf' says "It roughly maintains  CLI
> compatibility with Yum" where what "roughly" may eventually mean is anybodys
> guess.  At this stage I am not that interested in dnf.

Where does the yum man page mention 'copr'? It is unfair to open bugzillas, have people work on them and then casually mention you're not interested in the project.

Comment 13 Michal Jaegermann 2014-04-30 15:09:44 UTC
(In reply to Tim Lauridsen from comment #11)

> Where does the yum man page mention 'copr'?

I miss something.  Where 'copr' was mentioned in a context of yum.

> It is unfair to open bugzillas,
> have people work on them and then casually mention you're not interested in
> the project.

Well, I spent not that little time trying to figure out how I can use dnf and filing reports about what looked to me like problems.  This required somewhat more than a casual effort. It appears that dnf at this stage is still very much WIP and I need some "insider knowledge" to push that further.  A bit much for now.

Comment 14 Tim Lauridsen 2014-05-01 04:56:57 UTC
the copr command added by the dnf-plugins-core, the gives you a easy way to enable this copr repository

http://copr.fedoraproject.org/coprs/timlau/dnf-utils/

you can also download and install the .repo file in /etc/yum.repos.d

and use 'dnf install dnf-utils' to install the test package and

test the 'dnf dnl' command supplied by the package, to see if solves the same
need as yumdownloader does.

Comment 15 Tim Lauridsen 2014-06-02 07:47:26 UTC
download command is added to dnf-plugins-core-0.0.8, available in fedora updates

http://dnf-plugins-core.readthedocs.org/en/latest/download.html


Note You need to log in before you can comment on or make changes to this bug.