@task
@parallel
def bootstrap_configurator():
    if not hasattr(env, "bootmachine_servers"):
        abort("bootstrap_configurator(): Try `fab each bootstrap_configurator`")

    __set_ssh_vars(env)

    if exists("/root/.bootmachine_configurator_bootstrapped", use_sudo=True):
        print(green("{ip_addr} configurator is already bootstrapped, skipping.".format(
            ip_addr=env.host)))
        return

    print(cyan("... {ip_addr} configurator has begun bootstrapping .".format(ip_addr=env.host)))

    # bootstrap configurator
    server = [s for s in env.bootmachine_servers if s.public_ip == env.host][0]
    distro = import_module(server.distro_module)
    configurator.install(distro)
    configurator.setup(distro)
    configurator.start(distro)

    sudo("touch /root/.bootmachine_configurator_bootstrapped")
    print(green("{0} configurator is bootstrapped.".format(server.name)))
Bootstraps the configurator.
dataset/ETHPy150Open rizumu/bootmachine/bootmachine/core.py/bootstrap_configurator