S | |
save_entry, Redis | |
savedefault, Grub | |
schedule, Cron | |
Scope entry, Nslcd | |
screen, Xorg | |
script, Xymon_Alerting | |
search, Resolv | |
section, Xorg | |
section_entry, Xorg | |
selectors, Syslog | |
semicol, Channels | |
sensor, Ntpd | |
sep | |
sep_base64, Ldif | |
sep_colon | |
sep_line, Ldif | |
sep_moddir, Solaris_System | |
sep_modspec, Ldif | |
sep_opt_spc, Tmpfiles | |
sep_record, Ldif | |
sep_semi, Up2date | |
sep_space, Modprobe | |
sep_spc | |
sep_url, Ldif | |
sep_with_spc, Trapperkeeper | |
sep_ws, Aptsources | |
serial, Grub | |
server | |
servers, Ntpd | |
service | |
set, BootConf | |
set_sep_spc, Solaris_System | |
set_value, Solaris_System | |
set_var, Solaris_System | |
setkey, Grub | |
setting, Puppet_Auth | |
settings, Chrony | |
shell | |
shell_command, Hosts_Access | |
shellvar | |
simple | |
simple_entry, Nslcd | |
simple_entry_quoted_value, Nslcd | |
single | |
single_command, BootConf | |
single_entry, Up2date | |
single_opt | |
slaveof_entry, Redis | |
smoothtime, Chrony | |
smtp_check_field, Keepalived | |
smtp_host_check_field, Keepalived | |
softdep, Modprobe | |
sortlist, Resolv | |
space | |
space_or_eol | |
spc | |
spec, Sudoers | |
spec_list, Sudoers | |
Split, Util | |
squote_opt_nil, Test_Quote | |
squote_spaces, Quote | |
ssl_options, Rabbitmq | |
standard_entry, Redis | |
static_ipaddress_field, Keepalived | |
static_routes, Keepalived | |
static_routes_field, Keepalived | |
sto_bool, Host_Conf | |
sto_bool_warn, Host_Conf | |
sto_email_addr, Keepalived | |
sto_ipv6, Keepalived | |
sto_line, Modules | |
sto_no_colons, Modprobe | |
sto_no_spaces, Modprobe | |
sto_num, Keepalived | |
sto_to_colon, Hosts_Access | |
sto_to_eol | |
sto_value, Systemd | |
sto_value_single, Systemd | |
sto_word, Keepalived | |
stop, Xymon_Alerting | |
store_address, Chrony | |
store_word, Xymon_Alerting | |
stratum_re, Ntpd | |
stty, BootConf | |
switch, Grub | |
switch_arg, Grub |
Entries identified by the “save” keyword can be found more than once.
let save_entry = [ indent . key save . del_ws_spc . seconds . del_ws_spc . keys . eol ]
let savedefault = [ command "savedefault" "\t" . (spc . store Rx.integer)? . eol ]
Time in the format “@keyword”
let schedule = [ label "schedule" . Util.del_str "@" . store schedule_re ]
The Screen entry of ServerLayout
let screen = [ indent . del /[sS]creen/ "Screen" . label "Screen" . [ sep_spc . label "num" . store int ]? . ( sep_spc . quoted_non_empty_string_val . [ sep_spc . label "position" . store to_eol ]? )? . eol ]
The script recipient definition
let script = [ key "SCRIPT" . ws . [ label "script" . store_word ] . ws . [ label "recipient" . store_word ] . filters_opt ]
let search = Build.key_value_line_comment "search" Sep.space (Build.opt_list [label "domain" . store Rx.word] Sep.space) comment_eol
A section in xorg.conf
let section = [ indent . del "Section" "Section" . sep_spc . sep_dquote . key (section_re|section_re_obsolete) . sep_dquote . eol . section_entry* . indent . del "EndSection" "EndSection" . eol ]
let section_entry = option | screen | display | extmod | input_device | driver | identifier | videoram | default_depth | device | entry_generic | empty | comment
a list of selectors, separated by semicolons
let selectors = label_opt_list "selector" selector semicolon
let semicol = Util.del_str ";"
sensor device [correction microseconds] [weight weight-value] [refid string] [stratum stratum-value]
let sensor = let device = [ label "device" . store device_re ] in let correction = opt_value "correction" correction_re in let weight = opt_value "weight" weight_re in let refid = opt_value "refid" refid_re in let stratum = opt_value "stratum" stratum_re in [ key "sensor" . space . device . (space . correction)? . (space . weight)? . (space . refid)? . (space . stratum)? . eol ]
let sep = IniFile.sep IniFile.sep_re IniFile.sep_default
let sep = IniFile.sep "=" "="
let sep = IniFile.sep /=[ \t]*/ "="
The separator for network/mask entries
let sep = Util.del_ws_tab
let sep = IniFile.sep "=" "="
Key and values are separated by either spaces or an equal sign
let sep = del /([ \t]+)|([ \t]*=[ \t]*)/ " = "
An IniFile.sep entry
let sep = IniFile.sep "=" "="
let sep = IniFile.sep IniFile.sep_default IniFile.sep_default
An IniFile.sep entry
let sep = IniFile.sep "=" "="
let sep = del /[ \t]*[:=]/ ":"
The separator for attributes and base64 encoded values
let sep_base64 = del /::[ \t]*/ ":: "
The separator for attributes and values
let sep_colon = del /:[ \t]*/ ": "
The separator for database entries
let sep_colon = del /:[ \t]*/ ": "
The separator for key/value entries
let sep_colon = del /:[ \t]*/ ": "
let sep_line = empty | comment
The separator of directories in a moddir search path
let sep_moddir = del /[: ]+/ " "
Separator between modify operations
let sep_modspec = Util.del_str "-" . eol
Optional space (for the beginning of the lines)
let sep_opt_spc = Sep.opt_space
let sep_record = ( sep_line | attr_include )*
let sep_semi = Sep.semicolon
let sep_space = del /([ \t]|(\\\\\n))+/ " "
let sep_spc = Sep.space
Space
let sep_spc = Sep.space
let sep_with_spc = sep . Sep.opt_space
let sep_ws = Sep.space
let serial = [ command "serial" "" . [ spc . switch_arg /unit|port|speed|word|parity|stop|device/ ]* . eol ]
A simple server entry
let server = let address = /[A-Za-z0-9_.:\/-]+/ in [ Util.indent . label "@server" . Util.del_str "server" . [ Sep.space . label "@address" . store address ] . [ Sep.space . key word . (Sep.equal . store word)? ]* . Sep.semicolon . (Util.eol|Util.comment_eol) ]
server address [weight weight-value] [rtable table-id]
let server = let addr = [ label "address" . store address_re ] in key_opt_weight_rtable_line "server" addr
servers address [weight weight-value] [rtable table-id]
let servers = let addr = [ label "address" . store address_re ] in key_opt_weight_rtable_line "servers" addr
The service specification like `files’, `db’, or `nis’
let service = [ label "service" . store Rx.word ]
The (ex)?service filter definition
let service = kw_word /(EX)?SERVICE/
set [varname [value]]
let set = Build.key_value "set" space (key_opt_value_line set_cmd (store Rx.space_in))
let set_sep_spc = Util.del_opt_ws " "
Sets an integer value or char pointer
let set_value = [ label "value" . store Rx.no_spaces ]
Loads the variable name from a set command, no module
let set_var = [ label "variable" . store Rx.word ]
let setkey = [ command "setkey" "" . ( spc . [ label "to" . store Rx.no_spaces ] . spc . [ label "from" . store Rx.no_spaces ] )? . eol ]
let setting = list "environment" Rx.word | list "method" /find|search|save|destroy/ | list "allow" /[^# \t\n,][^#\n,]*[^# \t\n,]|[^# \t\n,]/ | list "allow_ip" /[A-Za-z0-9.:\/]+/ | auth
All supported chrony settings
let settings = host_list | allowdeny | log_list | bcast | fdrift | istepslew | local | email | makestep | maxchange | refclock | smoothtime | hwtimestamp | ratelimit | tempcomp | kv | all_flags
pw_shell
let shell = [ label "shell" . sto_to_eol? ]
pw_shell
let shell = [ label "shell" . sto_to_eol? ]
let shell_command = [ label "shell_command" . store shell_command_rx ]
A shell variable in crontab
let shellvar = Cron.shellvar
A shell variable in crontab
let shellvar = let key_re = /[A-Za-z1-9_-]+(\[[0-9]+\])?/ - "entry" in let sto_to_eol = store /[^\n]*[^ \t\n]/ in [ key key_re . sep_eq . sto_to_eol . eol ]
A simple entry
let simple = let kw = word - block_re_all in let mask = [ label "mask" . Util.del_str "/" . store Rx.integer ] in let sto = store /[^ \t\n;#]([^";#]|"[^"]*\")*/ in [ Util.indent . key kw . mask? . (Sep.space . sto)? . Sep.semicolon . (Util.eol|Util.comment_eol) ]
The simplest configuration option a key spc value.
let simple_entry (kw:string) = Build.key_ws_value kw
Simple entry with quoted value
let simple_entry_quoted_value (kw:string) = Build.key_value_line kw spc (do_dquote (store /.*/))
A single-quoted value
let single = let body = store /[^\n]*/ in do_squote body
let single = [ label "single" . Quote.single ]
single command such as ‘help’ or ‘time’
let single_command = let line_re = /help|time|reboot/ in [ Util.indent . key line_re . eol ]
key=foo
let single_entry = [ label "value" . store value_re ]
An optionally single-quoted value Single quotes are not allowed in value Value cannot begin or end with spaces
let single_opt = let body = store single_opt_re in do_squote_opt body
let single_opt = [ label "single_opt" . Quote.single_opt ]
Entries identified by the “slaveof” keyword can be found more than once.
let slaveof_entry = [ indent . key slaveof . del_ws_spc . ip . del_ws_spc . port . eol ]
smoothtime has specific syntax
let smoothtime = [ Util.indent . key "smoothtime" . space . [ label "maxfreq" . store number ] . space . [ label "maxwander" . store number ] . ( space . [ key "leaponly" ] )? . eol ]
let smtp_check_field = let word_re = "connect_ip" | "bindto" in let num_re = "connect_timeout" | "retry" | "delay_before_retry" in let to_eol_re = "helo_name" in field word_re sto_word | field num_re sto_num | field to_eol_re sto_to_eol | block "host" smtp_host_check_field
let smtp_host_check_field = let word_re = "connect_ip" | "bindto" in let num_re = "connect_port" in field word_re sto_word | field num_re sto_num
let softdep = let premod = [ label "pre" . sep_space . sto_no_colons ] in let pre = sep_space . Util.del_str "pre:" . premod+ in let postmod = [ label "post" . sep_space . sto_no_colons ] in let post = sep_space . Util.del_str "post:" . postmod+ in [ key "softdep" . sep_space . sto_no_colons . pre? . post? . Util.comment_or_eol ]
let sortlist = Build.key_value_line_comment "sortlist" Sep.space (Build.opt_list ipaddr Sep.space) comment_eol
Separation between key and value
let space = Util.del_ws_spc
let space = Sep.space
Separation between key and value
let space = Util.del_ws_spc
let space = Sep.space
let space = del /[ \t\n]*/ ""
let space = Sep.space
let space_or_eol = del /([ \t]*\n)?[ \t]+/ " "
let space_or_eol = del /([ \t]*\n)?[ \t]+/ " "
let space_or_eol (sep:regexp) (default:string) = del (space_or_eol_re? . sep . space_or_eol_re?) default
let spc = Util.del_ws_spc
let spc = Util.del_ws_spc
A user specification, listing colon-separated spec_lists
let spec = [ label "spec" . indent . alias_list "user" sto_to_com_user . sep_cont . Build.opt_list spec_list sep_col . comment_or_eol ]
Group of hosts with cmnd_spec_list
let spec_list = [ label "host_group" . alias_list "host" sto_to_com_host . sep_eq . cmnd_spec_list ]
let squote_opt_nil = let body = store Quote.single_opt_re in [ label "squote_opt_nil" . Quote.do_squote_opt_nil body ]?
Make single quotes mandatory if value contains spaces, and optional if value doesn’t contain spaces.
let squote_spaces (lns:lens) =
(Incomplete) list of SSL options
let ssl_options = let versions_list = Erlang.opt_list (Erlang.make_value Erlang.quoted) in let option = Erlang.value /((ca)?cert|key)file/ Erlang.path | Erlang.value "verify" Erlang.bare | Erlang.value "verify_fun" Erlang.boolean | Erlang.value /fail_if_no_peer_cert|reuse_sessions/ Erlang.boolean | Erlang.value "depth" Erlang.integer | Erlang.value "password" Erlang.quoted | Erlang.value "versions" versions_list in Erlang.list "ssl_options" option
A standard entry is a key-value pair, separated by blank space, with optional blank spaces at line beginning & end.
let standard_entry = let reserved_k = "save" | "rename-command" | "slaveof" | "bind" | "client-output-buffer-limit" in let entry_noempty = [ indent . key (k - reserved_k) . del_ws_spc . Quote.do_quote_opt_nil (store v) . eol ] in let entry_empty = [ indent . key (k - reserved_k) . del_ws_spc . dquote . store "" . dquote . eol ] in entry_noempty | entry_empty
The whole string is fed to ip addr add.
let static_ipaddress_field = [ indent . ipaddr . (sep_spc . ipdev)? . comment_or_eol ]
let static_routes = block "static_ipaddress" static_ipaddress_field | block "static_routes" static_routes_field
src $SRC_IP to $DST_IP dev $SRC_DEVICE
let static_routes_field = [ indent . label "route" . [ key "src" . sto_word ] . sep_spc . [ key "to" . sto_word ] . sep_spc . [ key "dev" . sto_word ] . comment_or_eol ]
Store a boolean value
let sto_bool = store ("on"|"off")
Store a boolean value
let sto_bool_warn = store ("on"|"off"|"warn"|"nowarn")
let sto_email_addr = store Rx.email_addr
let sto_ipv6 = store Rx.ipv6
let sto_line = store /[^# \t\n].*[^ \t\n]|[^# \t\n]/
let sto_no_colons = store /[^:# \t\n\\\\]+/
let sto_no_spaces = store /[^# \t\n\\\\]+/
let sto_num = store Rx.relinteger
Allows escaped colon sequences
let sto_to_colon = store /[^ \t\n:=][^\n:]*((\\\\:|\\\\[ \t]*\n[ \t]+)[^\n:]*)*[^ \\\t\n:]|[^ \t\n:\\\\]/
let sto_to_eol = store /[^#! \t\n][^#!\n]*[^#! \t\n]|[^#! \t\n]/
let sto_to_eol = store /(([^# \t\n\\\\][^#\n\\\\]*[ \t]*\\\\[ \t]*\n[ \t]*)*([^# \t\n\\\\][^#\n\\\\]*[^# \t\n\\\\]|[^# \t\n\\\\])|[^# \t\n\\\\])/
let sto_value = store /[^# \t\n]*[^# \t\n\\]/
Support multiline values with a backslash
let sto_value_single = Util.del_opt_ws "" . store (value_single_re . (/\\\\\n/ . value_single_re)*)
let sto_word = store word
The stop recipient definition
let stop = flag_filters_opt "STOP"
let store_address = [ label "address" . store address_re ]
let store_word = store /[^ =\t\n#]+/
value between 1 and 15
let stratum_re = /1[0-5]|[1-9]/
stty [device [speed]]
let stty = let device = [ label "device" . store fspath ] in let speed = [ label "speed" . store Rx.integer ] in key_opt_value_line "stty" (device . (space . speed)?)
let switch (n:regexp) = dels "--" . key n
let switch_arg (n:regexp) = switch n . eq . store Rx.no_spaces