> So it should be fairly easy to put a command in there that's going to read 
> your IP in from another file and set a variable you can use in the rules 
> file. Not done it myself, but it should work.

I'm having a chicken & egg problem.

Easy enough to have ddclient on my router populate

        /etc/MY_CURRENT_IP

with the IP result, then restart shorewall.

with 

        MY_SW_EXT_IP=$(cat /etc/MY_CURRENT_IP) shorewall-lite restart

if 'params' has something like

        [ -n "${MY_SW_EXT_IP:=127.0.0.1}" ]

, if I'm reading 

        http://shorewall.net/configuration_file_basics.htm

right.

But I've set this up so that I edit & compile my shorewall config on my 
desktop, then push to the remote box that's running the firewall.

        sh shorewall remote-reload -c -s ${MY_FIREWALL}

That doesn't seem to be grabbing the

        /etc/MY_CURRENT_IP

right at compile+push, until after I restart the firewall again.

Not sure how to make sure that it grabs that remote RUNTIME value correctly 
while making sure that compile-time doesn't complain about the local value 
being undefined.

DT

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Shorewall-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/shorewall-users

Reply via email to