# check if flag file update_ddnoc has been placed in /tmp # if so, remove it and run perl script to update the router # Another process can create a flag file, /tmp/update_routername, where # routername is the name of the router recognized by # opnsense-totp-ovpn-export # if that file exists, we remove it, then run the exporter with # the routername as a parameter. # opnsense-totp-ovpn-export explicitly uses a lockfile to ensure only one # copy is running at a time, so if more than one call is made, it is # theoretically safe. # set this to the fully qualified path to the export script SCRIPTLOCATION=/var/www/html/web_pages/totp_opnsense/opnsense-totp-ovpn-export # every minute, check if update_routername has been created * * * * * root if [ -f /tmp/update_routername ]; then rm /tmp/update_routername; $SCRIPTLOCATION routername; fi