I have an upstart script like so:
start on runlevel  respawn script exec su - ubuntu -c "cd /opt/app; bin/widget 2>&1 | logger -t 'widget'" end script
The problem is when the widget process crashes, it doesn't respawn. Presumably because the logger process is still running. Any way around this?