.\" Man page generated from reStructuredText. . . .nr rst2man-indent-level 0 . .de1 rstReportMargin \\$1 \\n[an-margin] level \\n[rst2man-indent-level] level margin: \\n[rst2man-indent\\n[rst2man-indent-level]] - \\n[rst2man-indent0] \\n[rst2man-indent1] \\n[rst2man-indent2] .. .de1 INDENT .\" .rstReportMargin pre: . RS \\$1 . nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin] . nr rst2man-indent-level +1 .\" .rstReportMargin post: .. .de UNINDENT . RE .\" indent \\n[an-margin] .\" old: \\n[rst2man-indent\\n[rst2man-indent-level]] .nr rst2man-indent-level -1 .\" new: \\n[rst2man-indent\\n[rst2man-indent-level]] .in \\n[rst2man-indent\\n[rst2man-indent-level]]u .. .TH "DNF5-CONFIG-MANAGER" "8" "Apr 18, 2025" "" "dnf5" .SH NAME dnf5-config-manager \- Config-manager Command .SH SYNOPSIS .sp \fBdnf5 config\-manager [options] [arguments]\fP .SH DESCRIPTION .sp Manages main configuration, repositories configuration, and variables. .SH SUBCOMMANDS .INDENT 0.0 .TP .B \fBaddrepo \-\-from\-repofile=REPO_CONFIGURATION_FILE_URL [\-\-create\-missing\-dir] [\-\-overwrite] [\-\-save\-filename=FILENAME]\fP Adds a new repositories configuration file specified by URL or local path. .sp The file is copied without changes. The destination file name can be defined using the \fB\-\-save\-filename\fP option, otherwise it is taken from the source specification. If the \fB\&.repo\fP extension is missing from the destination filename, it will be added. .sp The destination directory path is the first path stored in the \fBreposdir\fP option (by default \fB/etc/yum.repos.d\fP). Overwriting/replacing an existing file can be enabled using the \fB\-\-overwrite\fP option. Before the new repositories configuration file is finally saved, it is analyzed and tested for validity. Repository IDs are also tested. Repositories with the same ID must not be defined in other configuration files. .TP .B \fBaddrepo [\-\-id=REPO_ID] <\-\-set=REPO_OPTION=VALUE>+ [\-\-add\-or\-replace] [\-\-create\-missing\-dir] [\-\-overwrite] [\-\-save\-filename=FILENAME]\fP Adds a new repository defined using user options. .sp At least one of \fB\-\-set=baseurl=\fP, \fB\-\-set=mirrorlist=\fP, \fB\-\-set=metalink=\fP must be set to a non\-empty URL. The repository ID can be defined using the \fB\-\-id\fP option, otherwise it is generated from the URL. The destination file name can be defined using the \fB\-\-save\-filename\fP option, otherwise it is set to the repository ID. If the \fB\&.repo\fP extension is missing from the destination filename, it will be added. .sp The destination directory path is the first path stored in the \fBreposdir\fP option (by default \fB/etc/yum.repos.d\fP). Overwriting/replacing an existing file can be enabled using the \fB\-\-overwrite\fP option. Modifying an existing file can be enabled using the \fB\-\-add\-or\-replace\fP option. Modification means that the new repository is added to the existing file or a repository with the same ID is replaced in the file. Before the new repository configuration is finally saved, the repository ID is tested. A repository with the same ID must not be defined in another configuration file. .TP .B \fBsetopt [\-\-create\-missing\-dir] <[repoid.]option_name=value>+\fP Sets options in the main configuration file and in the repositories configuration override file. .sp The main configuration is read first from the files in the drop\-in directories and then from the main configuration file (by default \fB/etc/dnf/dnf.conf\fP). So, options from main configuration file are read last and override the values of the same options defined in the drop\-in directories. .sp The repositories configuration is read from the repository configuration files and then adjusted using repository configuration overrides. Repository configuration override files are read from the distribution repository override directory (\fB/usr/share/dnf5/repos.override.d\fP) and from the system repository override directory (\fB/etc/dnf/repos.override.d\fP). If a file with the same name is present in both override directories, only the file from the system override directory is used. Thus, the distribution override file can simply be masked by creating a file with the same name in the system override directory. All used override files are sorted alphabetically by their names and then applied in that order. The override from the next file overwrites the previous one\-\-\-the last override wins. .sp The \fBsetopt\fP command writes the repositories configuration overrides to a file named \fB99\-config_manager.repo\fP located in the system repository override directory. Repository settings are written only to this override file. The original repository configuration file is not changed. Reposiory ID may contain globs. Override files also support globs. But the \fBsetopt\fP command resolves the \fBrepoid\fP pattern, and overrides are set for each matching repository independently. This means repositories added later will not be affected by these overrides. .TP .B \fBunsetopt <[repoid.]option_name>+\fP Removes options from the main configuration file and from the repositories configuration override file. .sp The \fBunsetopt\fP command removes options from the main configuration file (by default \fB/etc/dnf/dnf.conf\fP). However, the options may be still defined in configuration files in drop\-in directories (for example, the default distribution configuration). .sp The \fBunsetopt\fP command removes repository configuration overides from the file named \fB99\-config_manager.repo\fP located in the system repository override directory. However, the overrides may be still defined in other repository override files (for example, the default distribution overrides). Empty sections are removed from the configuration override file. Repository ID may contain globs. In this case, the \fBrepoid\fP pattern is resolved and the override is removed from all matching sections. .TP .B \fBsetvar [\-\-create\-missing\-dir] +\fP Sets one or more variables. .sp Variables are loaded from multiple directories. The list of directory paths is taken from the \fBvarsdir\fP option. The \fBsetvar\fP command stores variables to the last directory in the list (by default \fB/etc/dnf/vars\fP). Variables from this directory are read last and override the values of the same variables defined in previous directories. In other words, the last directory has the highest priority. .sp Note: The variables \fBreleasever_major\fP and \fBreleasever_minor\fP are read\-only. Their values are generated from the \fBreleasever\fP variable. .TP .B \fBunsetvar +\fP Removes variables. .sp Variables are loaded from multiple directories. The list of directory paths is taken from the \fBvarsdir\fP option. The \fBunsetvar\fP command removes variables from the last directory in the list (by default \fB/etc/dnf/vars\fP). So, the variable may still exist in another directory in the list (for example, the default distribution value). .sp Note: The variables \fBreleasever_major\fP and \fBreleasever_minor\fP are generated automatically and connot be removed. .UNINDENT .sp \fBNOTE:\fP .INDENT 0.0 .INDENT 3.5 Override directories are also listed with examples in \fI\%Drop\-in repo directories\fP\&. .UNINDENT .UNINDENT .SH OPTIONS .INDENT 0.0 .TP .B \fB\-\-add\-or\-replace\fP Allow adding or replacing the repository with the same ID in the existing configuration file. .TP .B \fB\-\-create\-missing\-dir\fP Allow creation of missing directories. .TP .B \fB\-\-from\-repofile=REPO_CONFIGURATION_FILE_URL\fP Specifies the source configuration file with the new repositories. .TP .B \fB\-\-id=REPO_ID\fP Set ID for newly created repository. .TP .B \fB\-\-overwrite\fP Allow replacing the existing repository configuration file by new one. .TP .B \fB\-\-save\-filename=FILENAME\fP Set the name of the new repository configuration file. The \fB\&.repo\fP extension is added if it is missing. .TP .B \fB\-\-set=REPO_OPTION=VALUE\fP Set option in newly created repository. .UNINDENT .SH EXAMPLES .INDENT 0.0 .TP .B \fBdnf5 config\-manager addrepo \-\-from\-repofile=http://example.com/some/additional.repo\fP Download \fBadditional.repo\fP, test it, and put it in repository configuration directory. .TP .B \fBdnf5 config\-manager addrepo \-\-set=baseurl=http://example.com/different/repo\fP Create new repo file with \fBhttp://example.com/different/repo\fP as \fBbaseurl\fP and enable it. The repository ID and target file name is generated from \fBbaseurl\fP\&. .TP .B \fBdnf5 config\-manager addrepo \-\-set=baseurl=http://example.com/different/rep \-\-id=example \-\-set=enabled=0\fP Create new repo file with \fBhttp://example.com/different/repo\fP as \fBbaseurl\fP\&. Set repository ID to \fBexample\fP and disable it. .TP .B \fBdnf5 config\-manager setopt repoid1.enabled=1 repoid2.enabled=0\fP Sets override to enable repository identified by \fBrepoid1\fP and disable repository identified by \fBrepoid2\fP\&. .TP .B \fBdnf5 config\-manager setopt repo1.proxy=http://proxy.example.com:3128/ repo2.proxy=http://proxy.example.com:3128/\fP Sets override for \fBproxy\fP option in repositories with repository IDs \fBrepo1\fP and \fBrepo2\fP\&. .TP .B \fBdnf5 config\-manager setopt \(aq*\-debuginfo.pkg_gpgcheck=0\(aq\fP Sets override for the \fBpkg_gpgcheck\fP option in all repositories whose repository ID ends with \fB\-debuginfo\fP\&. .TP .B \fBdnf5 config\-manager unsetopt \(aq*\-debuginfo.pkg_gpgcheck\(aq\fP Remove override for the \fBpkg_gpgcheck\fP option in all repositories whose repository ID ends with \fB\-debuginfo\fP\&. .TP .B \fBdnf5 config\-manager setopt keepcache=1 log_size=10M\fP Enables the \fBkeepcache\fP main option and sets the maximum size of logger files to 10 mebibytes (10 * 1024 * 1024 bytes). .TP .B \fBdnf5 config\-manager unsetopt keepcache log_size\fP Removes \fBkeepcache\fP and \fBlog_size\fP from the main configuration file. .TP .B \fBdnf5 config\-manager setvar \-\-create\-missing\-dir myvar1=value1 myvar2=value2\fP Sets the variables \fBmyvar1\fP and \fBmyvar2\fP\&. Directory for the variables is created if it does not exist. .TP .B \fBdnf5 config\-manager unsetvar myvar1 myvar2\fP Removes \fBmyvar1\fP and \fBmyvar2\fP variables. .UNINDENT .SH SEE ALSO .INDENT 0.0 .TP .B Configuration: .nf \fBdnf5\-conf(5)\fP, \fI\%DNF5 Configuration Reference\fP .fi .sp .UNINDENT .SH AUTHOR See AUTHORS.md in dnf5 source distribution. .SH COPYRIGHT Contributors to the dnf5 project. .\" Generated by docutils manpage writer. .