[Bug 1154] New: Allow include statement to operate on directories and/or wildcards

bugzilla-daemon at netfilter.org bugzilla-daemon at netfilter.org
Sat Jun 3 08:49:47 CEST 2017


https://bugzilla.netfilter.org/show_bug.cgi?id=1154

            Bug ID: 1154
           Summary: Allow include statement to operate on directories
                    and/or wildcards
           Product: nftables
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: enhancement
          Priority: P5
         Component: nft
          Assignee: pablo at netfilter.org
          Reporter: hoxu at users.sf.net

ferm include statement [1] allows several ways to include multiple files:

```
If you specify a directory (with a trailing '/'), all files in this directory
are included, sorted alphabetically:

    @include 'ferm.d/';

The function @glob can be used to expand wild cards:

    @include @glob('*.include');

With a trailing pipe symbol, ferm executes a shell command and parses its
output:

    @include "/root/generate_ferm_rules.sh $HOSTNAME|"

ferm aborts, if return code is not 0.
```

I don't personally care about the shell command execution, but being able to
include directories and/or wildcards would be really useful. For example, if
you want to provision various applications to a server, and allow each to
install only the app-specific nftables rules (eg. in
/etc/nftables.d/app.ruleset).

[1] http://ferm.foo-projects.org/download/2.4/ferm.html#Includes

-- 
You are receiving this mail because:
You are watching all bug changes.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.netfilter.org/pipermail/netfilter-buglog/attachments/20170603/53cd85ec/attachment.html>


More information about the netfilter-buglog mailing list