1INNCONFVAL(1)             InterNetNews Documentation             INNCONFVAL(1)
2
3
4

NAME

6       innconfval - Get configuration parameters from configuration files
7

SYNOPSIS

9       innconfval [-pstv] [-f file] [-F filetype] [-i innconffile] [parameter
10       ...]
11
12       innconfval -C [-i innconffile]
13

DESCRIPTION

15       innconfval normally prints the values of the parameters specified on
16       the command line, from inn.conf.  By default, it just prints the
17       parameter values, but if -p, -s, or -t are given, it instead prints the
18       parameter and value in the form of a variable assignment in Perl,
19       Bourne shell, or Tcl respectively.  If no parameters are specifically
20       requested, innconfval prints out all parameter values (this isn't
21       particularly useful unless one of -p, -s, or -t were specified).
22
23       All parameters are taken from inn.conf except for version, which is
24       always the version string of INN.
25
26       Use the -f and -F options to specify another configuration file from
27       which to print the values of the parameters.
28
29       If given the -C option, innconfval instead checks inn.conf, reporting
30       any problems found to standard error.
31

OPTIONS

33       -C  Check inn.conf rather than printing out the values of parameters,
34           and exit with status 0 if no problems are found and with status 1
35           otherwise.
36
37       -f file
38           Use file as the source configuration file for the type mentioned in
39           the -F option.  If not set, the default configuration file is used
40           (that is to say the file in pathetc named like the type provided
41           with -F).  file must be a valid configuration file of that type and
42           will be parsed the same as that type would be.
43
44       -F filetype
45           filetype must either be "inn.conf" (the default) or
46           "inn-secrets.conf".  It defines the type of configuration file to
47           parse.
48
49           For instance, run "innconfval -F inn-secrets.conf canlockuser" to
50           retrieve the canlockuser value from inn-secrets.conf.
51
52           The default path to the configuration file of the requested type
53           will be used, unless -f is given (or a specific source
54           configuration file for inn.conf is set with -i and defines another
55           pathetc location).
56
57       -i innconffile
58           Use innconffile as the source configuration file for inn.conf
59           rather than inn.conf in pathetc.  innconffile must be a valid
60           inn.conf file and will be parsed the same as inn.conf would be.
61
62       -p  Print out parameters as Perl assignment statements.  The variable
63           name will be the same as the configuration parameter, and string
64           values will be enclosed in single quotes with appropriate escaping.
65           Boolean values will be mapped to the strings "true" or "false".
66           List values will be mapped to an array of strings.  NULL values are
67           printed out with the "undef" value.
68
69           Here is an example:
70
71               $enableoverview = 'true';
72               @extraoverviewadvertised = ( 'Newsgroups', 'Injection-Info' );
73               @extraoverviewhidden = undef;
74               $organization = 'Let\'s try nasty "quotes"';
75               $maxforks = 10;
76
77           If innconfval is called via the Perl "INN::Config" module, all
78           these variables are properly exported.
79
80       -s  Print out parameters as Bourne shell assignment statements.  The
81           variable name will be the configuration parameter name in all
82           capitals, and all variables will be exported, if not NULL.  String
83           values will be enclosed in single quotes with appropriate escaping,
84           and boolean values will be mapped to "true" or "false".  List
85           values will be mapped to a space-separated string representing an
86           array of strings (as Bourne shell does not recognize arrays,
87           contrary to several other shells, an array cannot be returned for
88           interoperability reasons).
89
90           Here is an example:
91
92               ENABLEOVERVIEW=true; export ENABLEOVERVIEW;
93               EXTRAOVERVIEWADVERTISED='"Newsgroups" "Injection-Info"';
94                   export EXTRAOVERVIEWADVERTISED;
95               ORGANIZATION='Let'\''s try nasty "quotes"'; export ORGANIZATION;
96               MAXFORKS=10; export MAXFORKS;
97
98       -t  Print out parameters as Tcl assignment statements.  The variable
99           name will be the same as the configuration parameter name but with
100           "inn_" prepended, and string variables will be escaped
101           appropriately.  Boolean values will be mapped to the strings "true"
102           or "false".  List values will be mapped to an array of strings.
103           NULL values are not printed out.
104
105           Here is an example:
106
107               set inn_enableoverview "true"
108               set inn_extraoverviewadvertised { "Newsgroups" "Injection-Info" }
109               set inn_organization "Let's try nasty \"quotes\""
110               set inn_maxforks 10
111
112       -v  Print INN's version and exit.  This is equivalent to "innconfval
113           version".
114

HISTORY

116       Written by Rich $alz <rsalz@uunet.uu.net> for InterNetNews.
117

SEE ALSO

119       inn.conf(5), inn-secrets.conf(5), INN::Config(3pm).
120
121
122
123INN 2.7.1                         2022-07-10                     INNCONFVAL(1)
Impressum