On Sun, Nov 17, 2019 at 11:57:44AM GMT, Unicorn wrote:
> Hello,
> 
> I apologize if this is trivial, I genuinely read through all the cron-
> related manpages and tried several things, but this is my issue:
> 
> I want to use 'autossh' to automatically establish reverse port
> forwarding on boot, so (as root) I can 'crontab -e' and added this line
> to the bottom:
> 
> @reboot autossh [all my options]
> 
> After adding the line, running 'crontab -l' shows that the line was
> correctly added; I have also confirmed that the 'autossh ...' part
> works perfectly when I just execute it in a terminal. When I reboot the
> system though, nothing happens.
> 
> Even if I restart cron with rcctl, nothing happens. I even confirmed
> that sshd is started before cron in rc, I have tried everything I could
> come up with, I just have no clue what I'm missing.
> 
> Since I am new to OpenBSD, I would appreciate your advice or any clues
> on what I have done wrong. Regarding system setup, this is a completely
> bare system, I have just run 'sysupgrade -s' and installed autossh.
> 
> Thank you in advance!
> 

At the top of the file you'll see:

        PATH=/bin:/sbin:/usr/bin:/usr/sbin

Either {pre,ap}pend /usr/local/{,s}bin or use the full command path.

Regards,

Raf

Reply via email to