1PAKITI-CLIENT(1) System Manager's Manual PAKITI-CLIENT(1)
2
3
4
6 pakiti-client - report the list of installed packages to a collecting
7 server
8
10 pakiti-client [OPTIONS]
11
13 pakiti-client finds the list of installed packages (i.e. "rpm -qa" on
14 an RPM-based system) and formats it in a report that it sends (using a
15 POST request) to a collecting server (see the --url option) and/or
16 writes to a file (see the --output option).
17
18 In addition to the list of installed packages, the report also contains
19 information about the submitting machine:
20
21 • "arch": the current architecture
22
23 • "host": the host name (see the --host option)
24
25 • "kernel": the current kernel
26
27 • "packager": the packager ("rpm" or "dpkg")
28
29 • "site": the site name (see the --site option)
30
31 • "system": the operating system full name
32
33 • "tag": a tag used by the collecting server (see the --tag option)
34
35 • "version": the report format version (1)
36
37 If a certificate (see the --encrypt option) is given then the report
38 will be S/MIME encrypted before transmission. For reference, the exact
39 command used to encrypt the report is:
40
41 $ openssl smime -encrypt -binary -aes-256-cbc -outform DER
42
43 The recommended way to use this program is daily via "cron", for
44 instance with (using bash):
45
46 # echo "MAILTO=somebody@some.where" > /etc/cron.d/pakiti-client
47 # echo "$((RANDOM % 60)) $((RANDOM % 24)) * * * nobody pakiti-client \
48 --config /etc/pakiti-client.cfg" >> /etc/cron.d/pakiti-client
49
51 --config, --conf PATH
52 use this configuration file before processing the command line
53 parameters
54
55 --curl PATH
56 set the path of the "curl" command to use
57
58 --debug, -d
59 enable debug mode
60
61 --dpkg-query PATH
62 set the path of the "dpkg-query" command to use
63
64 --encrypt PATH|STRING
65 use this certificate to encrypt the report; the value can either be
66 the path of the file containing the certificate or the certificate
67 itself as multi-line ASCII armored contents
68
69 --expect STRING
70 set the response string to expect from the server in case of
71 success (default: "OK")
72
73 --help, -h, -?
74 show some help
75
76 --host STRING
77 set the host name to use in the report
78
79 --hostname PATH
80 set the path of the "hostname" command to use
81
82 --input, -i PATH
83 do not prepare a new report but, instead, read the report from the
84 given file
85
86 --lsb_release PATH
87 set the path of the "lsb_release" command to use
88
89 --manual, -m
90 show this manual
91
92 --mode STRING
93 the mode that determines how the report should be processed by the
94 server. The following modes are supported: 'store-only',
95 'report-only', 'store-and-report'.
96
97 --no-protocol-version
98 do not include the protocol version in the message sent to the
99 server.
100
101 --openssl PATH
102 set the path of the "openssl" command to use
103
104 --output, -o PATH
105 write the prepared report to the given file
106
107 --pkg PATH
108 set the path of the "pkg" command to use
109
110 --rndsleep, -r NUMBER
111 sleep for a random amount of seconds, up to the given number
112 (useful when pakiti-client is invoked by "cron")
113
114 --rpm PATH
115 set the path of the "rpm" command to use
116
117 --site NAME
118 set the site name to use in the report
119
120 --tag STRING
121 set the tag used by the collecting server to group reports
122
123 --uname PATH
124 set the path of the "uname" command to use
125
126 --url URL
127 send the prepared report to the collecting server at the given URL
128
129 --wget PATH
130 set the path of the "wget" command to use
131
133 pakiti-client can read its options from a configuration file (see the
134 --config option).
135
136 The file can contain empty lines, comments (lines starting with "#") or
137 option settings either on one line or using the "heredoc" syntax. For
138 instance:
139
140 #
141 # this is my pakiti-client configuration
142 #
143 url = http://some.where.org:8080/some/path
144 encrypt = <<EOT
145 -----BEGIN CERTIFICATE-----
146 VR0gBF0wWzBZBgorBgEEAWAKBAsBMEswSQYIKwYBBQUHAgEWPWh0dHA6Ly9jYWZp
147 U2VydmljZXMsQ049U22ydmljZXMsQ049Q29uZmlndXJhdGlvbixEQz1jZXJuLERD
148 ...
149 CREUmgapD+aWdxEfeb6qA0OqAFCeHYOWMeeqqtMUE1JPGPoWNkyzqaObr05jm0zd
150 YwYIKwYBBQUHMAKGV2h0dHA6Ly6jYWZpbGVzLmNlcm4uY2gvY2FmaWxlcy9jZXJ=
151 -----END CERTIFICATE-----
152 EOT
153
154 The options specified on the command line have precedence over the ones
155 found in the configuration file.
156
158 The generated report is made of a header (containing information about
159 the submitting machine) and a body (containing the list of installed
160 packages).
161
162 The report is in text format and is made of lines, all ending with the
163 newline character (0x0A). The report contains in order:
164
165 • a first separator line indicating the beginning of the header
166
167 • one or more header lines
168
169 • a second separator line indicating the end of the header
170
171 • one or more package lines
172
173 • a third separator line indicating the end of the report
174
175 A separator line only contains the hash character (0x23), followed by
176 the newline character (just like any other line).
177
178 A header line contains the header name (such as "host"), a colon
179 character (0x3A), a space character (0x20) and the header value. See
180 the "DESCRIPTION" section for the list of all possible header names.
181
182 A package line contains the package name, a tab character (0x09), the
183 package full version, another tab and the package architecture. For
184 "rpm" based systems, the full version is in fact EPOCH:VERSION:RELEASE.
185
187 Lionel Cons <http://cern.ch/lionel.cons>
188
190 Copyright (C) CERN 2014-2016
191
192 Licensed under the Apache License, Version 2.0 (the "License"); you may
193 not use this file except in compliance with the License. You may obtain
194 a copy of the License at: <http://www.apache.org/licenses/LICENSE-2.0>.
195
196 Unless required by applicable law or agreed to in writing, software
197 distributed under the License is distributed on an "AS IS" BASIS,
198 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
199 implied. See the License for the specific language governing
200 permissions and limitations under the License.
201
202
203
204pakiti v3 2022-01-20 PAKITI-CLIENT(1)