feat(controller): allow restarts on error and add custom variables.