-
Notifications
You must be signed in to change notification settings - Fork 807
Closed
Description
Implement new setup and teardown functions for the agent.
The setup function should:
- Exit if any other agents are currently running on the same host
- Establish a connection with the Monkey Island
- Check if the agent has been marked for shutdown
- Report appropriate telemetry if the agent is running on the Island
- Upgrade from 32 -> 64bit agent if required (be careful not to recreate Mongo error in /api/telemetry #1059)
- Configure the host's firewall
- Start a tunnel
- Construct a Puppet and Master
- Register signal handlers (NOP for now, implemented in Implement signal handlers #1594)
- Start the master
The teardown function should:
- Stop the tunnel
- Restore original firewall rules
- Clean up the master
Tasks
- Refactor and clean up the agent setup/execute/teardown code. (0d) @ilija-lazoroski, @shreyamalviya