mirror of
https://gitlab.com/shorewall/code.git
synced 2025-05-31 23:15:48 +02:00
Describe the parameters passed to the enable and disable extension scripts
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
parent
657215f9b5
commit
56c8f70b52
@ -611,6 +611,44 @@ cat -</programlisting>
|
|||||||
</tgroup>
|
</tgroup>
|
||||||
</informaltable></para>
|
</informaltable></para>
|
||||||
|
|
||||||
|
<para>The contents of each run-time script is placed in a shell
|
||||||
|
function, so you can declare local variables and can use the
|
||||||
|
<command>return</command> command. The functions generated from the
|
||||||
|
<filename>enable</filename> and <filename>disable</filename> scripts are
|
||||||
|
passed three arguments:</para>
|
||||||
|
|
||||||
|
<variablelist>
|
||||||
|
<varlistentry>
|
||||||
|
<term>$1</term>
|
||||||
|
|
||||||
|
<listitem>
|
||||||
|
<para>Physical name of the interface that was enabled or
|
||||||
|
disabled.</para>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry>
|
||||||
|
<term>$2</term>
|
||||||
|
|
||||||
|
<listitem>
|
||||||
|
<para>Logical name of the interface.</para>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry>
|
||||||
|
<term>$3</term>
|
||||||
|
|
||||||
|
<listitem>
|
||||||
|
<para>Name of the Provider, if any, associated with the
|
||||||
|
interface.</para>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
|
</variablelist>
|
||||||
|
|
||||||
|
<para>As described above, the function generated from the
|
||||||
|
<filename>isusable</filename> script is passed a single argument that
|
||||||
|
names a network interface.</para>
|
||||||
|
|
||||||
<para>With the exception of postcompile, compile-time extension scripts
|
<para>With the exception of postcompile, compile-time extension scripts
|
||||||
are executed using the Perl 'eval `cat
|
are executed using the Perl 'eval `cat
|
||||||
<<emphasis>file</emphasis>>`' mechanism. Be sure that each script
|
<<emphasis>file</emphasis>>`' mechanism. Be sure that each script
|
||||||
|
Loading…
x
Reference in New Issue
Block a user