--- - hosts: target serial: 1 tasks: - name: "Check that -e 'action=[stop|start|restart]' was passed in" fail: msg: "The variable 'action' was not passed in with a value of 'stop', 'start' or 'restart' on the command line." when: action not in ["stop", "start", "restart"] - include: playbooks/tomcat-ctl.yaml