Postfix_Virtual - Augeas Documentation

# Postfix_Virtual

Parses /etc/postfix/virtual

Author: Raphael Pinson raphael.nosp@m..pinson@camptoc.nosp@m.amp.com

Summary

Postfix_Virtual | Parses /etc/postfix/virtual
Reference | This lens tries to keep as close as possible to `man 5 virtual` where possible.
License | This file is licenced under the LGPL v2+, like the rest of Augeas.
Lens Usage | To be documented
Configuration files | This lens applies to /etc/postfix/virtual.
Examples | The Test_Postfix_Virtual file contains various examples and tests.
Augeas Variables |
space_or_eol_re |
Augeas Lenses |
space_or_eol |
word |
comma |
destination |
record |
lns |
Augeas Variables |
filter |

### Reference

This lens tries to keep as close as possible to `man 5 virtual` where possible.

### License

This file is licenced under the LGPL v2+, like the rest of Augeas.

### Lens Usage

To be documented

### Configuration files

This lens applies to /etc/postfix/virtual. See filter.

### Examples

The Test_Postfix_Virtual file contains various examples and tests.

### Augeas Variables

### space_or_eol_re

> let space_or_eol_re = /([ \t]*\n)?[ \t]+/

### Augeas Lenses

### space_or_eol

> let space_or_eol (sep:regexp) (default:string) = del (space_or_eol_re? . sep . space_or_eol_re?) default

### word

> let word = store /[A-Za-z0-9@\*.+=_-]+/

### comma

> let comma = space_or_eol "," ", "

### destination

> let destination = [ label "destination" . word ]

### record

> let record = let destinations = Build.opt_list destination comma in [ label "pattern" . word . space_or_eol Rx.space " " . destinations . Util.eol ]

### lns

> let lns = (Util.empty | Util.comment | record)*

### Augeas Variables

### filter

Provides unit tests and examples for the Postfix_Virtual lens.

> let space_or_eol_re = /([ \t]*\n)?[ \t]+/

> let space_or_eol (sep:regexp) (default:string) = del (space_or_eol_re? . sep . space_or_eol_re?) default

> let word = store /[A-Za-z0-9@\*.+=_-]+/

> let comma = space_or_eol "," ", "

> let destination = [ label "destination" . word ]

> let record = let destinations = Build.opt_list destination comma in [ label "pattern" . word . space_or_eol Rx.space " " . destinations . Util.eol ]

> let lns = (Util.empty | Util.comment | record)*

Close