Blame doc/config_manager.rst

Packit 3a9065
..
Packit 3a9065
  Copyright (C) 2015  Red Hat, Inc.
Packit 3a9065
Packit 3a9065
  This copyrighted material is made available to anyone wishing to use,
Packit 3a9065
  modify, copy, or redistribute it subject to the terms and conditions of
Packit 3a9065
  the GNU General Public License v.2, or (at your option) any later version.
Packit 3a9065
  This program is distributed in the hope that it will be useful, but WITHOUT
Packit 3a9065
  ANY WARRANTY expressed or implied, including the implied warranties of
Packit 3a9065
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General
Packit 3a9065
  Public License for more details.  You should have received a copy of the
Packit 3a9065
  GNU General Public License along with this program; if not, write to the
Packit 3a9065
  Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
Packit 3a9065
  02110-1301, USA.  Any Red Hat trademarks that are incorporated in the
Packit 3a9065
  source code or documentation are not subject to the GNU General Public
Packit 3a9065
  License and may only be used or replicated with the express permission of
Packit 3a9065
  Red Hat, Inc.
Packit 3a9065
Packit 3a9065
==========================
Packit 3a9065
 DNF config-manager Plugin
Packit 3a9065
==========================
Packit 3a9065
Packit 3a9065
Manage main and repository DNF configuration options, toggle which
Packit 3a9065
repositories are enabled or disabled, and add new repositories.
Packit 3a9065
Packit 3a9065
--------
Packit 3a9065
Synopsis
Packit 3a9065
--------
Packit 3a9065
Packit 3a9065
``dnf config-manager [options] <section>...``
Packit 3a9065
Packit 3a9065
---------
Packit 3a9065
Arguments
Packit 3a9065
---------
Packit 3a9065
Packit 3a9065
``<section>``
Packit 3a9065
    This argument can be used to explicitly select the configuration sections to manage.
Packit 3a9065
    A section can either be ``main`` or a repoid.
Packit 3a9065
    If not specified, the program will select the ``main`` section and each repoid
Packit 3a9065
    used within any ``--setopt`` options.
Packit 3a9065
    A repoid can be specified using globs.
Packit 3a9065
Packit 3a9065
-------
Packit 3a9065
Options
Packit 3a9065
-------
Packit 3a9065
Packit 3a9065
All general DNF options are accepted, see `Options` in :manpage:`dnf(8)` for details.
Packit 3a9065
Packit 3a9065
``--help-cmd``
Packit 3a9065
    Show this help.
Packit 3a9065
Packit 3a9065
``--add-repo=URL``
Packit 3a9065
    Add (and enable) the repo from the specified file or url. If it has to be added into installroot, combine it with
Packit 3a9065
    ``--setopt=reposdir=/<installroot>/etc/yum.repos.d`` command-line option.
Packit 3a9065
Packit 3a9065
``--dump``
Packit 3a9065
    Print dump of current configuration values to stdout.
Packit 3a9065
Packit 3a9065
``--set-disabled``, ``--disable``
Packit 3a9065
    Disable the specified repos (implies ``--save``).
Packit 3a9065
Packit 3a9065
``--set-enabled``, ``--enable``
Packit 3a9065
    Enable the specified repos (implies ``--save``).
Packit 3a9065
Packit 3a9065
``--save``
Packit 3a9065
    Save the current options (useful with ``--setopt``).
Packit 3a9065
Packit 3a9065
``--setopt=<option>=<value>``
Packit 3a9065
    Set a configuration option. To set configuration options for repositories, use
Packit 3a9065
    ``repoid.option`` for the ``<option>``. Globs are supported in repoid.
Packit 3a9065
Packit 3a9065
--------
Packit 3a9065
Examples
Packit 3a9065
--------
Packit 3a9065
``dnf config-manager --add-repo http://example.com/some/additional.repo``
Packit 3a9065
    Download additional.repo and store it in repodir.
Packit 3a9065
Packit 3a9065
``dnf config-manager --add-repo http://example.com/different/repo``
Packit 3a9065
    Create new repo file with http://example.com/different/repo as baseurl and enable it.
Packit 3a9065
Packit 3a9065
``dnf config-manager --dump``
Packit 3a9065
    Display main DNF configuration.
Packit 3a9065
Packit 3a9065
``dnf config-manager --dump <section>``
Packit 3a9065
    Display configuration of a repository identified by <section>.
Packit 3a9065
Packit 3a9065
``dnf config-manager --set-enabled <repoid>``
Packit 3a9065
    Enable repository identified by <repoid> and make the change permanent.
Packit 3a9065
Packit Service 6746a6
``dnf config-manager --set-disabled <repoid1> <repoid2>``
Packit Service 6746a6
    Disable repositories identified by <repoid1> and <repoid2>
Packit Service 6746a6
Packit Service 6746a6
``dnf config-manager --set-disabled <repoid1>,<repoid2>``
Packit Service 6746a6
    Disable repositories identified by <repoid1> and <repoid2>
Packit Service 6746a6
Packit 3a9065
``dnf config-manager --save --setopt=*.proxy=http://proxy.example.com:3128/ <repo1> <repo2>``
Packit 3a9065
    Update proxy setting in repositories with repoid <repo1> and <repo2> and make the change
Packit 3a9065
    permanent.
Packit 3a9065
Packit 3a9065
``dnf config-manager --save --setopt=*-debuginfo.gpgcheck=0``
Packit 3a9065
    Update gpgcheck setting in all repositories whose id ends with -debuginfo and make the change permanent.