Struct tsunami::MachineSetup[][src]

pub struct MachineSetup { /* fields omitted */ }

A template for a particular machine setup in a tsunami.

Methods

impl MachineSetup
[src]

Define a new template for a tsunami machine setup.

The given AWS EC2 instance type will be used. Note that only EC2 Defined Duration Spot Instance types are allowed.

The setup argument is called once for every spawned instances of this type with a handle to the target machine. Use Machine::ssh to issue commands on the host in question.

The new instance will start out in the state dictated by the Amazon Machine Image specified in ami.

MachineSetup::new("m5.large", "ami-e18aa89b", |ssh| {
    ssh.cmd("cat /etc/hostname").map(|out| {
        println!("{}", out);
    })
});

Set the username to SSH into this machine type as.

Defaults to ec2-user.

Auto Trait Implementations

impl !Send for MachineSetup

impl Sync for MachineSetup