Import directly connected routes
Damien Clabaut
damien.clabaut at corp.ovh.com
Tue May 9 14:28:26 CEST 2017
Hello,
Thank you for your answer.
Are there some reserved variable names in function arguments ?
If I do (as per example in filter.conf in git repo):
function onef(string s)
{
return 1;
}
I get syntax error in the first line of the function. However,
function onef(string a)
{
return 1;
}
works.
Regards,
On 09/05/17 07:32 AM, Ondrej Zajicek wrote:
> On Mon, May 08, 2017 at 04:43:32PM -0400, Damien Clabaut wrote:
>> Hello again,
>>
>> Is there any way to declare a list of interfaces in a string set or
>> something ?
> No, string sets are not implemented. Although it is something that makes
> sense to add.
>
> You could define functions that match a set of string:
>
> function xxx(string s)
> {
> return s = "dev1" || s = "dev2" || s = "dev3";
> }
>
> Then you could use such functions in filters of direct and pipe protocol.
>
> Instead of:
>
> protocol direct direct_numa0 {
> table numa0;
> interface "eth4.800", "eth4.801";
> }
>
> You could use:
>
> protocol direct direct_numa0 {
> table numa0;
> import where xxx(ifname);
> }
>
>
--
Damien Clabaut
R&D vRouter
ovh.qc.ca
More information about the Bird-users
mailing list