Stop EC2 instance when sudoers file is changed with Puppet
This workflow is an example of responding to changes in a Puppet run. In this example, when a sudoers file change is detected, the workflow will stop the EC2 instance that is running the Puppet agent.
Before you run this workflow, you will need the following:
- An AWS account.
- An AWS IAM user with permissions to list and stop EC2 instances (if not run in dry run mode).
- Puppetserver with the Relay module installed. Check out the module for installation instructions.
Configure the workflow
You may need to update some of the secrets or connection information in this workflow to run in your environment.
- Add your AWS credentials for
- Add your preferred region under
Set up the trigger
Follow the instructions in the Relay module to set up the trigger.