openpkg/register.8

Mon, 28 Jan 2013 17:37:18 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Mon, 28 Jan 2013 17:37:18 +0100
changeset 758
a2c6460cfb16
permissions
-rw-r--r--

Correct socket error reporting improvement with IPv6 portable code,
after helpful recommendation by Saúl Ibarra Corretgé on OSips devlist.

michael@428 1 .\" Automatically generated by Pod::Man 2.25 (Pod::Simple 3.22)
michael@428 2 .\"
michael@428 3 .\" Standard preamble:
michael@428 4 .\" ========================================================================
michael@428 5 .de Sp \" Vertical space (when we can't use .PP)
michael@428 6 .if t .sp .5v
michael@428 7 .if n .sp
michael@428 8 ..
michael@428 9 .de Vb \" Begin verbatim text
michael@428 10 .ft CW
michael@428 11 .nf
michael@428 12 .ne \\$1
michael@428 13 ..
michael@428 14 .de Ve \" End verbatim text
michael@428 15 .ft R
michael@428 16 .fi
michael@428 17 ..
michael@428 18 .\" Set up some character translations and predefined strings. \*(-- will
michael@428 19 .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
michael@428 20 .\" double quote, and \*(R" will give a right double quote. \*(C+ will
michael@428 21 .\" give a nicer C++. Capital omega is used to do unbreakable dashes and
michael@428 22 .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff,
michael@428 23 .\" nothing in troff, for use with C<>.
michael@428 24 .tr \(*W-
michael@428 25 .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
michael@428 26 .ie n \{\
michael@428 27 . ds -- \(*W-
michael@428 28 . ds PI pi
michael@428 29 . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
michael@428 30 . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch
michael@428 31 . ds L" ""
michael@428 32 . ds R" ""
michael@428 33 . ds C`
michael@428 34 . ds C'
michael@428 35 'br\}
michael@428 36 .el\{\
michael@428 37 . ds -- \|\(em\|
michael@428 38 . ds PI \(*p
michael@428 39 . ds L" ``
michael@428 40 . ds R" ''
michael@428 41 'br\}
michael@428 42 .\"
michael@428 43 .\" Escape single quotes in literal strings from groff's Unicode transform.
michael@428 44 .ie \n(.g .ds Aq \(aq
michael@428 45 .el .ds Aq '
michael@428 46 .\"
michael@428 47 .\" If the F register is turned on, we'll generate index entries on stderr for
michael@428 48 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
michael@428 49 .\" entries marked with X<> in POD. Of course, you'll have to process the
michael@428 50 .\" output yourself in some meaningful fashion.
michael@428 51 .ie \nF \{\
michael@428 52 . de IX
michael@428 53 . tm Index:\\$1\t\\n%\t"\\$2"
michael@428 54 ..
michael@428 55 . nr % 0
michael@428 56 . rr F
michael@428 57 .\}
michael@428 58 .el \{\
michael@428 59 . de IX
michael@428 60 ..
michael@428 61 .\}
michael@428 62 .\"
michael@428 63 .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
michael@428 64 .\" Fear. Run. Save yourself. No user-serviceable parts.
michael@428 65 . \" fudge factors for nroff and troff
michael@428 66 .if n \{\
michael@428 67 . ds #H 0
michael@428 68 . ds #V .8m
michael@428 69 . ds #F .3m
michael@428 70 . ds #[ \f1
michael@428 71 . ds #] \fP
michael@428 72 .\}
michael@428 73 .if t \{\
michael@428 74 . ds #H ((1u-(\\\\n(.fu%2u))*.13m)
michael@428 75 . ds #V .6m
michael@428 76 . ds #F 0
michael@428 77 . ds #[ \&
michael@428 78 . ds #] \&
michael@428 79 .\}
michael@428 80 . \" simple accents for nroff and troff
michael@428 81 .if n \{\
michael@428 82 . ds ' \&
michael@428 83 . ds ` \&
michael@428 84 . ds ^ \&
michael@428 85 . ds , \&
michael@428 86 . ds ~ ~
michael@428 87 . ds /
michael@428 88 .\}
michael@428 89 .if t \{\
michael@428 90 . ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
michael@428 91 . ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
michael@428 92 . ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
michael@428 93 . ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
michael@428 94 . ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
michael@428 95 . ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
michael@428 96 .\}
michael@428 97 . \" troff and (daisy-wheel) nroff accents
michael@428 98 .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
michael@428 99 .ds 8 \h'\*(#H'\(*b\h'-\*(#H'
michael@428 100 .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
michael@428 101 .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
michael@428 102 .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
michael@428 103 .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
michael@428 104 .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
michael@428 105 .ds ae a\h'-(\w'a'u*4/10)'e
michael@428 106 .ds Ae A\h'-(\w'A'u*4/10)'E
michael@428 107 . \" corrections for vroff
michael@428 108 .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
michael@428 109 .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
michael@428 110 . \" for low resolution devices (crt and lpr)
michael@428 111 .if \n(.H>23 .if \n(.V>19 \
michael@428 112 \{\
michael@428 113 . ds : e
michael@428 114 . ds 8 ss
michael@428 115 . ds o a
michael@428 116 . ds d- d\h'-1'\(ga
michael@428 117 . ds D- D\h'-1'\(hy
michael@428 118 . ds th \o'bp'
michael@428 119 . ds Th \o'LP'
michael@428 120 . ds ae ae
michael@428 121 . ds Ae AE
michael@428 122 .\}
michael@428 123 .rm #[ #] #H #V #F C
michael@428 124 .\" ========================================================================
michael@428 125 .\"
michael@428 126 .IX Title "REGISTER 8"
michael@428 127 .TH REGISTER 8 "OpenPKG" "REGISTER(8)" "OpenPKG"
michael@428 128 .\" For nroff, turn off justification. Always turn off hyphenation; it makes
michael@428 129 .\" way too many mistakes in technical documents.
michael@428 130 .if n .ad l
michael@428 131 .nh
michael@428 132 .SH "NAME"
michael@428 133 openpkg register \- OpenPKG Registry Command\-Line Client
michael@428 134 .SH "SYNOPSIS"
michael@428 135 .IX Header "SYNOPSIS"
michael@428 136 \&\fBregister\fR [\-u|\-\-user=<user|token>] [\-l|\-\-link=<token>] [\fI\-d|\-\-desc=<text\fR>]
michael@428 137 [\-m|\-\-mode=fake|post|wipe] [\fI\-a|\-\-args=<args\fR>]
michael@428 138 [\fI\-\-plat=<text\fR>] [\fI\-\-orel=<text\fR>] [\fI\-\-uuid=<file\fR>]
michael@428 139 [\fI\-\-conf=<file\fR>] [\fI\-\-prep=<file\fR>] [\fI\-\-tran=<file\fR>]
michael@428 140 [\fI\-\-util=<file\fR>] [\-\-data=<tag>[,<tag>...]]
michael@428 141 [\fI\-P|\-\-preparation\fR] [\fI\-T|\-\-transaction\fR]
michael@428 142 [\fI\-U|\-\-utilization\fR] [\fI\-C|\-\-convenience\fR]
michael@428 143 [\fI\-I|\-\-interaction\fR]
michael@428 144 [\fI\-v|\-\-verbose\fR] [\fI\-h|\-\-help\fR]
michael@428 145 .PP
michael@428 146 \&\fBregister\fR \-S|\-\-printstatus
michael@428 147 .PP
michael@428 148 \&\fBregister\fR \-R|\-\-rewriteurls [\fIurl\fR ...]
michael@428 149 .SH "DESCRIPTION"
michael@428 150 .IX Header "DESCRIPTION"
michael@428 151 \&\fBopenpkg register\fR is the Command-Line Client the OpenPKG Registry. It is
michael@428 152 used by administrators to register an instance with the OpenPKG Registry for
michael@428 153 later association.
michael@428 154 .PP
michael@428 155 After association, \fBopenpkg register\fR can be used for repetitive
michael@428 156 reregistrations which update the heartbeat of the instance on the Registry
michael@428 157 server, avoiding premature depature from the database. It is assumed that
michael@428 158 every instance will be reregistered daily. Dormant
michael@428 159 instances might be discarded from the Registry, revoking their access to
michael@428 160 additional resources.
michael@428 161 .SH "PRIMARY OPERATIONS"
michael@428 162 .IX Header "PRIMARY OPERATIONS"
michael@428 163 The following primary operations are available:
michael@428 164 .IP "\fB\-h\fR, \fB\-\-help\fR" 4
michael@428 165 .IX Item "-h, --help"
michael@428 166 Display brief usage message.
michael@428 167 .IP "\fB\-v\fR, \fB\-\-verbose\fR" 4
michael@428 168 .IX Item "-v, --verbose"
michael@428 169 Display progress information during data posting.
michael@428 170 .IP "\fB\-P\fR, \fB\-\-preparation\fR" 4
michael@428 171 .IX Item "-P, --preparation"
michael@428 172 Execute the primary operation \*(L"preparation\*(R".
michael@428 173 Creates registry data for one request and dumps it stdout
michael@428 174 in \s-1XML\s0 format. That request can be filtered and piped into
michael@428 175 the transaction phase or it can be copied and pasted into the
michael@428 176 XMLdump \s-1CGI\s0 facility manually.
michael@428 177 A copy of the output of the last run is also saved to the \f(CW\*(C`${REGISTRY_PREP}\*(C'\fR file.
michael@428 178 .IP "\fB\-T\fR, \fB\-\-transaction\fR" 4
michael@428 179 .IX Item "-T, --transaction"
michael@428 180 Execute the primary operation \*(L"transaction\*(R".
michael@428 181 Reads registry data with one request from stdin, executes
michael@428 182 the transaction and writes registry data with one or more
michael@428 183 responses to stdout in \s-1XML\s0 format.
michael@428 184 Depending on the mode of operation, the transaction might be an actual
michael@428 185 transport to the XMLdump \s-1CGI\s0 facility or a fake activity which complements the
michael@428 186 manual preparation.
michael@428 187 A copy of the output of the last run is also saved to the \f(CW\*(C`${REGISTRY_TRAN}\*(C'\fR file.
michael@428 188 .IP "\fB\-U\fR, \fB\-\-utilization\fR" 4
michael@428 189 .IX Item "-U, --utilization"
michael@428 190 Execute the primary operation \*(L"utilization\*(R".
michael@428 191 Reads registry data with one response from stdin and updates the local
michael@428 192 registry information.
michael@428 193 Depending on the mode of operation, the utilization might be an actual
michael@428 194 processing of a transaction response or a fake activity which complements the
michael@428 195 manual transaction.
michael@428 196 Anyway, this step finalizes the registration process and makes the instance
michael@428 197 assume it has been properly registered. This status can be printed. \s-1URL\s0
michael@428 198 rewriting is activated.
michael@428 199 A copy of the output of the last run is also saved to the \f(CW\*(C`${REGISTRY_UTIL}\*(C'\fR file.
michael@428 200 .IP "\fB\-C\fR, \fB\-\-convenience\fR" 4
michael@428 201 .IX Item "-C, --convenience"
michael@428 202 Execute the primary operation \*(L"convenience\*(R".
michael@428 203 This executes the three primary operations \*(L"preparation\*(R", \*(L"transaction\*(R" and
michael@428 204 \&\*(L"utilization\*(R" in that order and pipes data through this chain.
michael@428 205 .IP "\fB\-I\fR, \fB\-\-interaction\fR" 4
michael@428 206 .IX Item "-I, --interaction"
michael@428 207 Execute the primary operation \*(L"interaction\*(R".
michael@428 208 Like \*(L"convenience\*(R" but user is interactively asked for information. This is
michael@428 209 the easiest way to do registration but it is not meat to be automated.
michael@428 210 .IP "\fB\-S\fR, \fB\-\-printstatus\fR" 4
michael@428 211 .IX Item "-S, --printstatus"
michael@428 212 If the instance has been registered, information about the registration is printed in a
michael@428 213 format suitable for shell evaluation and return code is true.
michael@428 214 Otherwise nothing is printed and return code is false.
michael@428 215 .IP "\fB\-R\fR, \fB\-\-rewriteurls\fR [\fIurl\fR ...]" 4
michael@428 216 .IX Item "-R, --rewriteurls [url ...]"
michael@428 217 If the instance has been registered, the given URLs are rewritten to prepend
michael@428 218 user:pass information before hostnames below the openpkg.(org|net|com)
michael@428 219 domains. Note the username is is \s-1UUID_REGISTRY\s0 and the password is the
michael@428 220 concatenation of \s-1UUID_INSTANCE\s0 and \s-1UUID_PLATFORM\s0 from the
michael@428 221 PREFIX/etc/openpkg/uuid file. Both informations are not meant to be used for
michael@428 222 traditional authentication, they are merly statistical information.
michael@428 223 Otherwise the URLs are returned verbatim.
michael@428 224 .SH "STANDARD OPTIONS"
michael@428 225 .IX Header "STANDARD OPTIONS"
michael@428 226 Standard options are typically used to automate registration (not
michael@428 227 association).
michael@428 228 .IP "\fB\-m\fR, \fB\-\-mode\fR fake|post|wipe" 4
michael@428 229 .IX Item "-m, --mode fake|post|wipe"
michael@428 230 Overrides \f(CW\*(C`${REGISTRY_MODE}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 231 Has no default and is a manadatory setting.
michael@428 232 .Sp
michael@428 233 In \fBpost\fR mode, transactions are carried out using real network connectivity.
michael@428 234 The \*(L"preparation\*(R" step creates a XMLdump and writes it into the
michael@428 235 \&\f(CW\*(C`${REGISTRY_PREP}\*(C'\fR file. The \*(L"transaction\*(R" step posts it to the DropXML form
michael@428 236 using a \s-1HTTP\s0 request. The response coming back from Registration server is
michael@428 237 also in \s-1XML\s0 format and is saved to \f(CW\*(C`${REGISTRY_TRAN}\*(C'\fR file. The
michael@428 238 \&\*(L"utilization\*(R" step processes this response and writes the final results to the
michael@428 239 \&\f(CW\*(C`${REGISTRY_UTIL}\*(C'\fR file.
michael@428 240 .Sp
michael@428 241 In \fBfake\fR mode, no network connectivity takes place.
michael@428 242 The \*(L"prepararation\*(R" step creates a XMLdump and writes it into the
michael@428 243 \&\f(CW\*(C`${REGISTRY_PREP}\*(C'\fR file. The \*(L"transaction\*(R" step is a fake only. It assumes a
michael@428 244 successful response from the Registration server and saves it to
michael@428 245 \&\f(CW\*(C`${REGISTRY_TRAN}\*(C'\fR file. The \*(L"utilization\*(R" step processes this response and
michael@428 246 writes the final results to the \f(CW\*(C`${REGISTRY_UTIL}\*(C'\fR file.
michael@428 247 \&\fINote\fR: fake mode is meant as a way to register instances which cannot or must
michael@428 248 not post data directly to the Registration server.
michael@428 249 .Sp
michael@428 250 In \fBwipe\fR mode, the registration is wiped out locally. The status is reset
michael@428 251 and \s-1URL\s0 rewriting is disabled.
michael@428 252 \&\fINote\fR: the registration server is not contacted, the instace must be removed
michael@428 253 manually using the web interface.
michael@428 254 \&\fINote\fR: wiping registration is highly recommended as a precursor action of
michael@428 255 cloning activities.
michael@428 256 .ie n .IP "\fB\-a\fR, \fB\-\-args\fR ""arg [arg ...]""" 4
michael@428 257 .el .IP "\fB\-a\fR, \fB\-\-args\fR ``arg [arg ...]''" 4
michael@428 258 .IX Item "-a, --args arg [arg ...]"
michael@428 259 Overrides \f(CW\*(C`${REGISTRY_ARGS}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 260 Complements the mode and is specific to it.
michael@428 261 Defaults to \*(L"http://registry.openpkg.org/register\*(R" which is the official registry of the OpenPKG Project.
michael@428 262 This default is useful for \*(L"post\*(R" mode.
michael@428 263 .IP "\fB\-u\fR, \fB\-\-user\fR \fIuser|token\fR" 4
michael@428 264 .IX Item "-u, --user user|token"
michael@428 265 Overrides \f(CW\*(C`${REGISTRY_USER}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 266 Indicates the registry user which will find this registration in his arrival queue.
michael@428 267 The user can also specified as a token which is enabled for use as \*(L"user\*(R".
michael@428 268 If the token is also enabled for \*(L"assoc\*(R" the registered instance is immediately associated
michael@428 269 to the user with no need for the user to visit the web interface.
michael@428 270 This information in submitted via the \*(L"registry_user\*(R" attribute of the \s-1XML\s0 request.
michael@428 271 Retrieves default online from http://openpkg.org/go/autoregister and is a manadatory setting.
michael@428 272 .IP "\fB\-l\fR, \fB\-\-link\fR \fItoken\fR" 4
michael@428 273 .IX Item "-l, --link token"
michael@428 274 Overrides \f(CW\*(C`${REGISTRY_LINK}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 275 Indicates the registry user which will find this registration linked to his token.
michael@428 276 The link must be specified as a token which is enabled for use as \*(L"link\*(R".
michael@428 277 If a user token is used and the link token is also enabled for \*(L"assoc\*(R" then the registered instance
michael@428 278 is immediately associated to the user with no need for the user to visit the web interface.
michael@428 279 This information in submitted via the \*(L"registry_link\*(R" attribute of the \s-1XML\s0 request.
michael@428 280 Has no default and is an optional setting.
michael@428 281 Be aware that linked users see the same information about an instance as the associated user
michael@428 282 can find on his \*(L"association\*(R" page but they cannot alter or delete information.
michael@428 283 .IP "\fB\-d\fR, \fB\-\-desc\fR \fIdescription\fR" 4
michael@428 284 .IX Item "-d, --desc description"
michael@428 285 Overrides \f(CW\*(C`${REGISTRY_DESC}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 286 Indicates a human readable description of the instance.
michael@428 287 This information in submitted via the \*(L"registry_desc\*(R" attribute of the \s-1XML\s0 request.
michael@428 288 It appears in the \*(L"description\*(R" column on the \*(L"association\*(R" page of the web form and can be edited on the server side.
michael@428 289 Defaults to \*(L"openpkg://${\s-1FQDN\s0}${\s-1PREFIX\s0}\*(R"
michael@428 290 .SH "ADVANCED OPTIONS"
michael@428 291 .IX Header "ADVANCED OPTIONS"
michael@428 292 Advanced options can be enganged to tailor and fully automate a registration
michael@428 293 (not association).
michael@428 294 .IP "\fB\-\-plat\fR" 4
michael@428 295 .IX Item "--plat"
michael@428 296 Overrides \f(CW\*(C`${REGISTRY_PLAT}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 297 Indicates the platform. Concatenated information from \s-1CPU\s0 architecture (arch) and Operating System (os).
michael@428 298 This information in submitted via the \*(L"registry_plat\*(R" attribute of the \s-1XML\s0 request.
michael@428 299 Defaults to \*(L"%{l_platform \-p}\*(R", e.g. \*(L"ix86\-freebsd6.1\*(R"
michael@428 300 .IP "\fB\-\-orel\fR" 4
michael@428 301 .IX Item "--orel"
michael@428 302 Overrides \f(CW\*(C`${REGISTRY_VERS}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 303 Indicates the OpenPKG release.
michael@428 304 This information in submitted via the \*(L"registry_orel\*(R" attribute of the \s-1XML\s0 request.
michael@428 305 Defaults to \*(L"%{l_openpkg_release}\*(R", e.g. \*(L"OpenPKG-CURRENT\*(R", \*(L"OpenPKG\-2\-STABLE\*(R", \*(L"OpenPKG\-2.5\*(R",
michael@428 306 .IP "\fB\-\-uuid\fR" 4
michael@428 307 .IX Item "--uuid"
michael@428 308 Overrides \f(CW\*(C`${REGISTRY_UUID}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 309 Indicates the \s-1UUID\s0 file of the instance.
michael@428 310 This information in submitted via the \*(L"uuid_registry\*(R", \*(L"uuid_instance\*(R" and \*(L"uuid_platform\*(R" attributes of the \s-1XML\s0 request.
michael@428 311 Defaults to \fI${\s-1PREFIX\s0}/etc/openpkg/uuid\fR
michael@428 312 .IP "\fB\-\-conf\fR" 4
michael@428 313 .IX Item "--conf"
michael@428 314 Overrides \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR variable from previous \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file. Processing
michael@428 315 of the current configuration file is aborted immediately with all variables
michael@428 316 read so far kept. THe new configuration file is read in immediately and
michael@428 317 processing continues there. This works similar to an include but is more
michael@428 318 primitive as it does not allow nesting, only chaining.
michael@428 319 Defaults to \fI${\s-1PREFIX\s0}/etc/openpkg/register.conf\fR
michael@428 320 .IP "\fB\-\-prep\fR" 4
michael@428 321 .IX Item "--prep"
michael@428 322 Overrides \f(CW\*(C`${REGISTRY_PREP}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 323 File to save a copy of the output from the \*(L"preparation\*(R" step.
michael@428 324 Defaults to \fI${\s-1PREFIX\s0}/etc/openpkg/register.prep\fR
michael@428 325 .IP "\fB\-\-tran\fR" 4
michael@428 326 .IX Item "--tran"
michael@428 327 Overrides \f(CW\*(C`${REGISTRY_TRAN}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 328 File to save a copy of the output from the \*(L"transaction\*(R" step.
michael@428 329 Defaults to \fI${\s-1PREFIX\s0}/etc/openpkg/register.tran\fR
michael@428 330 .IP "\fB\-\-util\fR" 4
michael@428 331 .IX Item "--util"
michael@428 332 Overrides \f(CW\*(C`${REGISTRY_UTIL}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 333 File to save a copy of the output from the \*(L"utilization\*(R" step.
michael@428 334 Defaults to \fI${\s-1PREFIX\s0}/etc/openpkg/register.util\fR
michael@428 335 .IP "\fB\-\-data\fR" 4
michael@428 336 .IX Item "--data"
michael@428 337 Overrides \f(CW\*(C`${REGISTRY_DATA}\*(C'\fR variable in \f(CW\*(C`${REGISTRY_CONF}\*(C'\fR file.
michael@428 338 Comma separated list of tags to prepare. Available tags are \*(L"request\*(R",
michael@428 339 \&\*(L"package\*(R" and \*(L"provides\*(R". The \*(L"request\*(R" refers to the whole thing and
michael@428 340 is mandatory. The \*(L"package\*(R" includes name-version-release information
michael@428 341 for all installed packages and \*(L"provides\*(R" adds more details required to
michael@428 342 capture package options. For details see \s-1OPENPKG_PREP\s0 below.
michael@428 343 Defaults to \*(L"request,package,provides\*(R"
michael@428 344 .SH "FILES"
michael@428 345 .IX Header "FILES"
michael@428 346 The following files are used by \fBopenpkg register\fR:
michael@428 347 .IP "OPENPKG_UUID=\fI${\s-1PREFIX\s0}/etc/openpkg/uuid\fR" 4
michael@428 348 .IX Item "OPENPKG_UUID=${PREFIX}/etc/openpkg/uuid"
michael@428 349 .Vb 3
michael@428 350 \& UUID_REGISTRY="..."
michael@428 351 \& UUID_INSTANCE="..."
michael@428 352 \& UUID_PLATFORM="..."
michael@428 353 .Ve
michael@428 354 .IP "OPENPKG_CONF=\fI${\s-1PREFIX\s0}/etc/openpkg/register.conf\fR" 4
michael@428 355 .IX Item "OPENPKG_CONF=${PREFIX}/etc/openpkg/register.conf"
michael@428 356 Format suitable for shell evaluation. Interactive mode appends remarked date
michael@428 357 and current settings for reuse as new defaults for future runs. Can be preset
michael@428 358 to customize or automate registration.
michael@428 359 .IP "OPENPKG_PREP=\fI${\s-1PREFIX\s0}/etc/openpkg/register.prep\fR" 4
michael@428 360 .IX Item "OPENPKG_PREP=${PREFIX}/etc/openpkg/register.prep"
michael@428 361 .Vb 10
michael@428 362 \& <?xml version="1.0" encoding="iso\-8859\-1" standalone="no"?>
michael@428 363 \& <!DOCTYPE registry
michael@428 364 \& PUBLIC "\-//OpenPKG//DTD OpenPKG Registry 0.0.1//EN"
michael@428 365 \& "http://registry.openpkg.org/registry.dtd" []>
michael@428 366 \& <registry>
michael@428 367 \& <request id="..."
michael@428 368 \& registry_user="me@example.com"
michael@428 369 \& registry_desc="openpkg://rm0.openpkg.net/openpkg\-dev"
michael@428 370 \& registry_plat="ix86\-freebsd6.1"
michael@428 371 \& registry_orel="OpenPKG\-CURRENT"
michael@428 372 \& uuid_registry="..."
michael@428 373 \& uuid_instance="..."
michael@428 374 \& uuid_platform="..."
michael@428 375 \& />
michael@428 376 \& <package id="..." name="ssmtp" version="2.61" release="20050608">
michael@428 377 \& <provides name="ssmtp::with_ssl" flag="=" version="no"/>
michael@428 378 \& <provides name="MTA" flag="" version=""/>
michael@428 379 \& <provides name="ssmtp" flag="=" version="2.61\-20050608"/>
michael@428 380 \& </package>
michael@428 381 \& </registry>
michael@428 382 .Ve
michael@428 383 .Sp
michael@428 384 The \s-1XML\s0 request starts with <?xml version ...> and <!DOCTYPE registry ...>
michael@428 385 headers followed by a <registry> container. The request is inside a <request>
michael@428 386 tag. Successful submission into the XMLdump form requires the headers and
michael@428 387 exactly one container. It is possible to merge multiple requests into a single
michael@428 388 container manually or otherwise and submit them all at once.
michael@428 389 .IP "OPENPKG_TRAN=\fI${\s-1PREFIX\s0}/etc/openpkg/register.tran\fR" 4
michael@428 390 .IX Item "OPENPKG_TRAN=${PREFIX}/etc/openpkg/register.tran"
michael@428 391 .Vb 7
michael@428 392 \& <?xml version="1.0" encoding="iso\-8859\-1" standalone="no"?>
michael@428 393 \& <!DOCTYPE registry
michael@428 394 \& PUBLIC "\-//OpenPKG//DTD OpenPKG Registry 0.0.1//EN"
michael@428 395 \& "http://registry.openpkg.org/registry.dtd" []>
michael@428 396 \& <registry>
michael@428 397 \& <response id="..." done="yes">openpkg://rm0.openpkg.net/openpkg\-dev</response>
michael@428 398 \& </registry>
michael@428 399 .Ve
michael@428 400 .Sp
michael@428 401 The \s-1XML\s0 response starts with <?xml version ...> and <!DOCTYPE registry ...>
michael@428 402 headers followed by a <registry> container. The response is inside a <request>
michael@428 403 tag. The data carried in the tag comes from the \*(L"description\*(R" column on the
michael@428 404 \&\*(L"association\*(R" page of the web form and can be edited on the server side.
michael@428 405 .IP "OPENPKG_UTIL=\fI${\s-1PREFIX\s0}/etc/openpkg/register.util\fR" 4
michael@428 406 .IX Item "OPENPKG_UTIL=${PREFIX}/etc/openpkg/register.util"
michael@428 407 .Vb 3
michael@428 408 \& REGISTRY_DBID="..."
michael@428 409 \& REGISTRY_DONE="yes"
michael@428 410 \& REGISTRY_RESP="openpkg://foo.example.com/my/openpkg/prefix"
michael@428 411 .Ve
michael@428 412 .SH "EXAMPLES"
michael@428 413 .IX Header "EXAMPLES"
michael@428 414 .Vb 10
michael@428 415 \& # su \- openpkg\-mop
michael@428 416 \& $ openpkg register \-\-printstatus
michael@428 417 \& REGISTRY_DBID="..."
michael@428 418 \& REGISTRY_DONE="yes"
michael@428 419 \& REGISTRY_RESP="openpkg://foo.example.com/my/openpkg/prefix"
michael@428 420 \& $ openpkg register \-\-printstatus >/dev/null && echo "Yup"
michael@428 421 \& Yup
michael@428 422 \& $ eval \`openpkg register \-\-printstatus\`; echo DONE=$REGISTRY_DONE
michael@428 423 \& DONE=yes
michael@428 424 \& $ openpkg register \-\-mode=wipe
michael@428 425 \& $ openpkg register \-\-printstatus || echo "Nope"
michael@428 426 \& Nope
michael@428 427 \& $ openpkg register \-\-user=thl@openpkg.net \-\-mode=post
michael@428 428 \& REGISTRY_DBID="...."
michael@428 429 \& REGISTRY_DONE="yes"
michael@428 430 \& REGISTRY_RESP="openpkg://foo.example.com/my/openpkg/prefix"
michael@428 431 \& $ openpkg register \-\-printstatus >/dev/null && echo "Yup"
michael@428 432 \& Yup
michael@428 433 \& $ openpkg register \-\-rewriteurls http://download.openpkg.org/foo/bar
michael@428 434 \& ftp://...:...@download.openpkg.org/foo/bar
michael@428 435 .Ve
michael@428 436 .SH "SEE ALSO"
michael@428 437 .IX Header "SEE ALSO"
michael@428 438 \&\fIbash\fR\|(1), \f(CW\*(C`openpkg man uuid\*(C'\fR, \f(CW\*(C`http://registry.openpkg.org/\*(C'\fR
michael@428 439 .SH "AUTHOR"
michael@428 440 .IX Header "AUTHOR"
michael@428 441 Thomas Lotterer <thl@openpkg.org>

mercurial