Man pages sections > man8 > puppet-config

puppet-config - Interact with Puppet´s settings.



puppet-config - Interact with Puppet´s settings.


puppet config action [--section SECTION_NAME]


This subcommand can inspect and modify settings from Puppet´s ´puppet.conf´ configuration file. For documentation about individual settings, see


Note that any setting that´s valid in the configuration file is also a valid long argument, although it may or may not be relevant to the present action. For example, server and run_mode are valid settings, so you can specify --server <servername>, or --run_mode <runmode> as an argument.
See the configuration file documentation at for the full list of acceptable parameters. A commented list of all configuration options can also be generated by running puppet with --genconfig.
--render-as FORMAT
The format in which to render output. The most common formats are json, s (string), yaml, and console, but other options such as dot are sometimes available.
Whether to log verbosely.
Whether to log debug information.
--section SECTION_NAME
The section of the puppet.conf configuration file to interact with.
The three most commonly used sections are ´main´, ´master´, and ´agent´. ´Main´ is the default, and is used by all Puppet applications. Other sections can override ´main´ values for specific applications --- the ´master´ section affects puppet master and puppet cert, and the ´agent´ section affects puppet agent.
Less commonly used is the ´user´ section, which affects puppet apply. Any other section will be treated as the name of a legacy environment (a deprecated feature), and can only include the ´manifest´ and ´modulepath´ settings.


print - Examine Puppet´s current settings.
puppet config print [--section SECTION_NAME] (all | setting [ setting ...]
Prints the value of a single setting or a list of settings.
This action is an alternate interface to the information available with puppet <subcommand> --configprint.
By default, this action reads the general configuration in the ´main´ section. Use the ´--section´ and ´--environment´ flags to examine other configuration domains.
set - Set Puppet´s settings.
puppet config set [--section SECTION_NAME] [setting_name] [setting_value]
Updates values in the puppet.conf configuration file.
By default, this action manipulates the configuration in the ´main´ section. Use the ´--section´ flag to manipulate other configuration domains.


Get puppet´s runfile directory:
$ puppet config print rundir
Get a list of important directories from the master´s config:
$ puppet config print all --section master | grep -E "(path|dir)"
Set puppet´s runfile directory:
$ puppet config set rundir /var/run/puppetlabs
Set the vardir for only the agent:
$ puppet config set vardir /opt/puppetlabs/puppet/cache --section agent Copyright 2011 by Puppet Labs Apache 2 license; see COPYING
May 2015 Puppet Labs, LLC