to execute a bash script from within a rule, read:
& http://docs.openhab.org/addons/bindings/exec1/readme.html