1PUPPET-NODE(8) Puppet manual PUPPET-NODE(8)
2
3
4
6 puppet-node - View and manage node definitions.
7
9 puppet node action [--terminus _TERMINUS]
10
12 This subcommand interacts with node objects, which are used by Puppet
13 to build a catalog. A node object consists of the node´s facts, envi‐
14 ronment, node parameters (exposed in the parser as top-scope vari‐
15 ables), and classes.
16
18 Note that any setting that´s valid in the configuration file is also a
19 valid long argument, although it may or may not be relevant to the
20 present action. For example, server and run_mode are valid settings, so
21 you can specify --server <servername>, or --run_mode <runmode> as an
22 argument.
23
24 See the configuration file documentation at https://pup‐
25 pet.com/docs/puppet/latest/configuration.html for the full list of ac‐
26 ceptable parameters. A commented list of all configuration options can
27 also be generated by running puppet with --genconfig.
28
29 --render-as FORMAT
30 The format in which to render output. The most common formats
31 are json, s (string), yaml, and console, but other options such
32 as dot are sometimes available.
33
34 --verbose
35 Whether to log verbosely.
36
37 --debug
38 Whether to log debug information.
39
40 --terminus _TERMINUS
41 Indirector faces expose indirected subsystems of Puppet. These
42 subsystems are each able to retrieve and alter a specific type
43 of data (with the familiar actions of find, search, save, and
44 destroy) from an arbitrary number of pluggable backends. In Pup‐
45 pet parlance, these backends are called terminuses.
46
47 Almost all indirected subsystems have a rest terminus that in‐
48 teracts with the puppet master´s data. Most of them have addi‐
49 tional terminuses for various local data models, which are in
50 turn used by the indirected subsystem on the puppet master when‐
51 ever it receives a remote request.
52
53 The terminus for an action is often determined by context, but
54 occasionally needs to be set explicitly. See the "Notes" section
55 of this face´s manpage for more details.
56
58 clean - Clean up signed certs, cached facts, node objects, and reports
59 for a node stored by the puppetmaster
60 SYNOPSIS
61
62 puppet node clean [--terminus _TERMINUS] host1 [host2 ...]
63
64 DESCRIPTION
65
66 Cleans up the following information a puppet master knows about
67 a node:
68
69 Signed certificates - ($vardir/ssl/ca/signed/node.domain.pem)
70
71 Cached facts - ($vardir/yaml/facts/node.domain.yaml)
72
73 Cached node objects - ($vardir/yaml/node/node.domain.yaml)
74
75 Reports - ($vardir/reports/node.domain)
76
77 NOTE: this action now cleans up certs via Puppet Server´s CA
78 API. A running server is required for certs to be cleaned.
79
80 find - Retrieve a node object.
81 SYNOPSIS
82
83 puppet node find [--terminus _TERMINUS] host
84
85 DESCRIPTION
86
87 Retrieve a node object.
88
89 RETURNS
90
91 A hash containing the node´s classes, environment, expiration,
92 name, parameters (its facts, combined with any ENC-set parame‐
93 ters), and time. When used from the Ruby API: a Puppet::Node ob‐
94 ject.
95
96 RENDERING ISSUES: Rendering as string and json are currently
97 broken; node objects can only be rendered as yaml.
98
99 info - Print the default terminus class for this face.
100 SYNOPSIS
101
102 puppet node info [--terminus _TERMINUS]
103
104 DESCRIPTION
105
106 Prints the default terminus class for this subcommand. Note that
107 different run modes may have different default termini; when in
108 doubt, specify the run mode with the ´--run_mode´ option.
109
111 find
112
113 Retrieve an "empty" (no classes, no ENC-imposed parameters, and an en‐
114 vironment of "production") node:
115
116 $ puppet node find somenode.puppetlabs.lan --terminus plain --render-as
117 yaml
118
119 Retrieve a node using the Puppet Server´s configured ENC:
120
121 $ puppet node find somenode.puppetlabs.lan --terminus exec --run_mode
122 server --render-as yaml
123
124 Retrieve the same node from the Puppet Server:
125
126 $ puppet node find somenode.puppetlabs.lan --terminus rest --render-as
127 yaml
128
130 This subcommand is an indirector face, which exposes find, search,
131 save, and destroy actions for an indirected subsystem of Puppet. Valid
132 termini for this face include:
133
134 • exec
135
136 • json
137
138 • memory
139
140 • msgpack
141
142 • plain
143
144 • rest
145
146 • store_configs
147
148 • yaml
149
150
151
153 Copyright 2011 by Puppet Inc. Apache 2 license; see COPYING
154
155
156
157Puppet, Inc. October 2023 PUPPET-NODE(8)