Module Expr Str Import alias Import alias Import alias Import alias Import alias ImportFrom alias alias alias alias ImportFrom alias alias ImportFrom alias alias alias alias alias alias alias ImportFrom alias ImportFrom alias identifier ImportFrom alias ImportFrom alias Import alias ImportFrom alias ImportFrom alias Expr Call NameLoad NameLoad Assign AttributeStore NameLoad attr Num FunctionDef arguments args NameParam defaults body Expr Str TryExcept body Expr Call NameLoad NameLoad Return SubscriptLoad AttributeLoad NameLoad attr Index NameLoad handlers ExceptHandler type NameLoad body Expr Call NameLoad Call AttributeLoad Str attr NameLoad decorator_list Assign NameStore Call NameLoad AttributeLoad NameLoad attr Assign NameStore Call NameLoad AttributeLoad NameLoad attr FunctionDef arguments args defaults body Expr Str Expr Call NameLoad Assign AttributeStore NameLoad attr NameLoad Expr Call NameLoad Assign NameStore Call NameLoad Str keyword NameLoad If CompareNotIn Str NameLoad body Print Call NameLoad Str Return Expr Call NameLoad Str Print Call NameLoad Str Expr Call NameLoad Str Print Call NameLoad Str Expr Call NameLoad Print Call NameLoad Str decorator_list Call NameLoad keyword NameLoad FunctionDef arguments args defaults body Expr Str If UnaryOpNot Call NameLoad NameLoad Str body Expr Call NameLoad Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr While NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Num If UnaryOpNot CompareIn SubscriptLoad NameLoad Index Str ListComp AttributeLoad NameLoad attr comprehension NameStore AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Print Call NameLoad Str Assign AttributeStore NameLoad attr NameLoad Print Call NameLoad Str Return Print Call NameLoad Str decorator_list NameLoad FunctionDef arguments args defaults body Expr Str If UnaryOpNot Call NameLoad NameLoad Str body Expr Call NameLoad Str Expr Call NameLoad NameLoad If Call NameLoad Str keyword NameLoad body Print Call NameLoad Call AttributeLoad Str attr keyword AttributeLoad NameLoad attr Return Print Call NameLoad Call AttributeLoad Str attr keyword AttributeLoad NameLoad attr Assign NameStore SubscriptLoad ListComp NameLoad comprehension NameStore AttributeLoad NameLoad attr CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr Index Num Assign NameStore Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call NameLoad Str Print Call NameLoad Call AttributeLoad Str attr AttributeLoad NameLoad attr decorator_list NameLoad NameLoad FunctionDef arguments args defaults body Expr Str If UnaryOpNot Call NameLoad NameLoad Str body Expr Call NameLoad Str Expr Call NameLoad NameLoad If Call NameLoad Str keyword NameLoad body Print Call NameLoad Call AttributeLoad Str attr keyword AttributeLoad NameLoad attr Return Print Call NameLoad Call AttributeLoad Str attr keyword AttributeLoad NameLoad attr Assign NameStore SubscriptLoad ListComp NameLoad comprehension NameStore AttributeLoad NameLoad attr CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr Index Num Assign NameStore Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad Str Print Call NameLoad Call AttributeLoad Str attr AttributeLoad NameLoad attr decorator_list NameLoad NameLoad FunctionDef arguments args defaults body Expr Str Expr Call NameLoad Expr Call AttributeLoad NameLoad attr Assign NameStore Num Expr Call NameLoad While AttributeLoad NameLoad attr body If CompareNotEq NameLoad Num body Expr Call NameLoad Str If CompareEq NameLoad Num body Expr Call NameLoad Str AugAssignAdd NameStore Num Print Call NameLoad Call AttributeLoad Str attr NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr For NameStore AttributeLoad NameLoad attr body Assign NameStore Call NameLoad NameLoad If CompareEq AttributeLoad NameLoad attr Call NameLoad AttributeLoad NameLoad attr body Expr Call NameLoad AttributeLoad NameLoad attr orelse Print Call NameLoad Call AttributeLoad Str attr NameLoad AttributeLoad NameLoad attr Expr Call NameLoad NameLoad Expr Call NameLoad Assign NameStore Call NameLoad Str keyword NameLoad If CompareIn Str NameLoad body Print Call NameLoad Str decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Str Expr Call NameLoad TryExcept body Assign NameStore SubscriptLoad ListComp NameLoad comprehension NameStore AttributeLoad NameLoad attr CompareEq AttributeLoad NameLoad attr NameLoad Index Num handlers ExceptHandler type NameLoad body Expr Call NameLoad Call AttributeLoad Str attr NameLoad Assign NameStore AttributeLoad NameLoad attr Assign NameStore AttributeLoad NameLoad attr TryExcept body Assign AttributeStore NameLoad attr Num Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Str handlers ExceptHandler type NameLoad body Assign AttributeStore NameLoad attr Call NameLoad AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad Str attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Num With Call NameLoad keyword NameLoad body Expr Call NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list NameLoad FunctionDef arguments args defaults body Expr Str For NameStore AttributeLoad NameLoad attr body If CompareNotEq AttributeLoad NameLoad attr Str body Expr Call NameLoad Call AttributeLoad Str attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call NameLoad NameLoad If CompareNotIn Call AttributeLoad Str attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call NameLoad Str Return TryExcept body Expr Call NameLoad Str Expr Call NameLoad Str handlers ExceptHandler body Expr Call NameLoad Str decorator_list NameLoad NameLoad FunctionDef arguments args defaults body Expr Str Expr Call NameLoad For NameStore AttributeLoad NameLoad attr body If CompareNotIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr If CompareNotIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args defaults body Expr Str Expr Call NameLoad For NameStore AttributeLoad NameLoad attr body If CompareEq AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad Str attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args defaults body Expr Str Expr Call AttributeLoad NameLoad attr For NameStore AttributeLoad NameLoad attr body If CompareEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr NameLoad Assign NameStore Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str If CompareEq NameLoad NameLoad body Assign NameStore AttributeLoad NameLoad attr orelse Assign NameStore AttributeLoad NameLoad attr TryExcept body Assign NameStore Num Expr Call AttributeLoad NameLoad attr NameLoad NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Assign AttributeStore NameLoad attr NameLoad If CompareEq AttributeLoad NameLoad attr Num body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Str orelse Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad Str attr NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args defaults body Assign AttributeStore NameLoad attr ListLoad For NameStore AttributeLoad NameLoad attr body If CompareNotEq AttributeLoad NameLoad attr Call NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list Expr Call AttributeLoad Call AttributeLoad NameLoad attr Str attr AttributeLoad NameLoad attr
N/A N/A 
BOOTMACHINE: A-Z transmutation of aluminium into rhodium.
 N/A copy N/A getpass N/A logging N/A sys N/A telnetlib fabric.api env local run sudo fabric.decorators parallel task fabric.colors blue cyan green magenta red white yellow fabric.contrib.files exists fabric.context_managers settings fabric_settings fabric.operations reboot fabric.utils abort N/A settings bootmachine known_hosts bootmachine.settings_validator validate_settings N/A N/A validate_settings settings N/A N/A env connection_attempts 12 import_module N/A N/A module N/A N/A N/A 
    Allows custom providers, configurators and distros.

    Import the provider, configurator, or distro module via a string.
        ex. ``bootmachine.contrib.providers.rackspace_openstack_v2``
        ex. ``bootmachine.contrib.configurators.salt``
        ex. ``bootmachine.contrib.distros.arch_201208``
     N/A N/A N/A N/A __import__ module N/A N/A N/A sys modules N/A module N/A N/A N/A ImportError N/A N/A N/A abort N/A N/A Unable to import the module: {0} format module N/A N/A provider N/A import_module N/A settings PROVIDER_MODULE N/A configurator N/A import_module N/A settings CONFIGURATOR_MODULE bootmachine N/A N/A N/A N/A N/A 
    Boot, bootstrap and configure all servers as per the settings.

    Usage:
        fab bootmachine
     N/A N/A master N/A N/A env new_server_booted False N/A N/A boot N/A output N/A local fab each ssh_test capture True N/A N/A CONFIGURATOR FAIL! output N/A N/A N/A green all servers are fully provisioned. N/A N/A N/A local fab each bootstrap_distro N/A N/A green the distro is bootstrapped on all servers. N/A N/A local fab each bootstrap_configurator N/A N/A green the configurator is bootstrapped on all servers. N/A N/A configure N/A N/A green all servers are fully provisioned. N/A N/A task default True boot N/A N/A N/A N/A N/A 
    Boot servers as per the config.

    Usage:
        fab boot
     N/A N/A N/A hasattr env bootmachine_servers N/A N/A N/A master N/A servers N/A N/A copy copy N/A settings SERVERS N/A servers N/A N/A server N/A N/A servers pop 0 N/A N/A N/A N/A server N/A servername N/A N/A s name N/A s N/A env bootmachine_servers N/A N/A N/A N/A provider bootem N/A settings SERVERS N/A N/A green new server(s) have been booted. N/A N/A env new_server_booted True N/A N/A green all servers are booted. N/A N/A N/A green all servers are booted. N/A task bootstrap_distro N/A N/A N/A N/A N/A 
    Bootstraps the distro.

    In parallel for speed.

    Usage:
        fab each bootstrap_distro
     N/A N/A N/A hasattr env bootmachine_servers N/A N/A N/A abort bootstrap_distro(): Try `fab each bootstrap_distro` N/A N/A __set_ssh_vars env N/A N/A exists /root/.bootmachine_distro_bootstrapped use_sudo True N/A N/A N/A green N/A N/A {ip_addr} distro is already bootstrapped, skipping. format ip_addr N/A env host N/A N/A N/A cyan N/A N/A ... {ip_addr} distro has begun bootstrapping . format ip_addr N/A env host N/A server N/A N/A s N/A s N/A env bootmachine_servers N/A N/A s public_ip N/A env host N/A 0 N/A distro N/A import_module N/A server distro_module N/A N/A N/A distro bootstrap N/A N/A sudo touch /root/.bootmachine_distro_bootstrapped N/A N/A green N/A N/A {0} distro is bootstrapped. format N/A server name N/A task parallel bootstrap_configurator N/A N/A N/A N/A N/A 
    Bootstraps the configurator.
    Installs the configurator and starts its processes.
    Does not run the configurator.

    Assumes the distro has been bootstrapped on all servers.

    In parallel for speed.

    Usage:
        fab each bootstrap_distro
     N/A N/A N/A hasattr env bootmachine_servers N/A N/A N/A abort bootstrap_configurator(): Try `fab each bootstrap_configurator` N/A N/A __set_ssh_vars env N/A N/A exists /root/.bootmachine_configurator_bootstrapped use_sudo True N/A N/A N/A green N/A N/A {ip_addr} configurator is already bootstrapped, skipping. format ip_addr N/A env host N/A N/A N/A cyan N/A N/A ... {ip_addr} configurator has begun bootstrapping . format ip_addr N/A env host N/A server N/A N/A s N/A s N/A env bootmachine_servers N/A N/A s public_ip N/A env host N/A 0 N/A distro N/A import_module N/A server distro_module N/A N/A N/A configurator install distro N/A N/A N/A configurator setup distro N/A N/A N/A configurator start distro N/A N/A sudo touch /root/.bootmachine_configurator_bootstrapped N/A N/A green N/A N/A {0} configurator is bootstrapped. format N/A server name N/A task parallel configure N/A N/A N/A N/A N/A 
    Configure all unconfigured servers.

    Assumes the distro and configurator have been bootstrapped on all
    servers.

    Usage:
        fab configure
     N/A N/A master N/A N/A N/A configurator launch N/A attempts 0 N/A N/A __set_unconfigured_servers N/A N/A env unconfigured_servers N/A N/A N/A attempts 0 N/A N/A N/A local fab master configurator.restartall N/A N/A attempts 5 N/A N/A N/A abort unable to configure the servers N/A attempts 1 N/A N/A yellow N/A N/A attempt #{0} for {1} format attempts N/A env unconfigured_servers N/A N/A N/A configurator configure N/A server N/A env unconfigured_servers N/A N/A server N/A __set_ssh_vars server N/A N/A N/A server port N/A int N/A settings SSH_PORT N/A N/A N/A reboot_server N/A server name N/A N/A N/A red N/A N/A after #{0} attempts, server {1} is still unconfigured format attempts N/A server name N/A N/A __set_ssh_vars env N/A N/A __set_unconfigured_servers N/A output N/A local fab each ssh_test capture True N/A N/A CONFIGURATOR FAIL! output N/A N/A N/A red configurator failure. N/A task reboot_server N/A N/A name N/A N/A N/A 
    Simply reboot a server by name.
    The trick here is to change the env vars to that of the server
    to be rebooted. Perform the reboot and change env vars back
    to their original value.

    Usage:
        fab reboot_server:name
     N/A N/A __shared_setup N/A N/A N/A server N/A N/A s N/A s N/A env bootmachine_servers N/A N/A s name name N/A 0 N/A N/A N/A IndexError N/A N/A N/A abort N/A N/A The server '{0}' was not found. format name N/A original_user N/A env user N/A original_host_string N/A env host_string N/A N/A N/A N/A env port 22 N/A N/A N/A telnetlib Telnet N/A server public_ip N/A env port N/A N/A env user root N/A N/A N/A IOError N/A N/A N/A env port N/A int N/A settings SSH_PORT N/A N/A env user N/A N/A getpass getuser N/A N/A N/A telnetlib Telnet N/A server public_ip N/A env port N/A N/A env host_string N/A N/A {0}:{1} format N/A server public_ip N/A env port N/A N/A env keepalive 30 N/A N/A fabric_settings warn_only True N/A N/A N/A reboot N/A N/A env user original_user N/A N/A env host_string original_host_string N/A task ssh_test N/A N/A N/A N/A N/A 
    Prove that ssh is open on `settings.SSH_PORT`.

    Usage:
        fab each ssh_test
     N/A server N/A env bootmachine_servers N/A N/A N/A N/A server status ACTIVE N/A N/A N/A abort N/A N/A The server '{0}' is in the '{1}' state. format N/A server name N/A server status N/A N/A __set_ssh_vars env N/A N/A N/A N/A :{0} format N/A settings SSH_PORT N/A env host_string N/A N/A N/A local echo 'CONFIGURATOR FAIL!' N/A N/A N/A N/A N/A run echo 'CONFIGURATOR SUCCESS!' N/A N/A sudo echo 'CONFIGURATOR SUCCESS!' N/A N/A N/A N/A N/A local echo 'CONFIGURATOR FAIL!' N/A task parallel each N/A N/A N/A N/A N/A 
    Set the env variables for a command to be run on all servers.

    Warning::
        Bootmachine assumes 'one' master and therefore
        currently does not support a multi-master configuration.
     N/A N/A __shared_setup N/A server N/A env bootmachine_servers N/A N/A N/A N/A server public_ip N/A env hosts N/A N/A N/A N/A N/A env hosts append N/A server public_ip N/A N/A N/A server public_ip N/A env all_hosts N/A N/A N/A N/A N/A env all_hosts append N/A server public_ip N/A task master N/A N/A N/A N/A N/A 
    Set the env variables for a command only to be run on the master server.
     N/A N/A __shared_setup N/A server N/A env bootmachine_servers N/A N/A N/A N/A server name N/A N/A env master_server name N/A N/A N/A env port N/A server port N/A N/A env user N/A server user N/A N/A N/A N/A env hosts append N/A server public_ip N/A N/A env host N/A server public_ip N/A N/A env host_string N/A N/A {0}:{1} format N/A server public_ip N/A server port N/A task __shared_setup N/A N/A N/A N/A N/A 
    Set the env variables common to both master() and each().
     N/A N/A N/A provider set_bootmachine_servers N/A server N/A env bootmachine_servers N/A N/A N/A N/A server name N/A settings MASTER N/A N/A N/A env master_server server N/A server N/A __set_ssh_vars server N/A N/A N/A known_hosts add N/A server user N/A server public_ip N/A server port N/A __set_ssh_vars N/A N/A valid_object N/A N/A N/A 
    This method takes a valid_object, either the env or a server,
    and based on the results of telnet, it sets port, user,
    host_string varibles for ssh. It also sets a configured
    variable if the SSH_PORT matches that in the settings. This
    would only match if the server is properly configured.
     N/A N/A valid_object env N/A N/A public_ip N/A env host N/A N/A public_ip N/A valid_object public_ip N/A N/A N/A port 22 N/A N/A N/A telnetlib Telnet public_ip port N/A N/A N/A IOError N/A N/A port N/A int N/A settings SSH_PORT N/A N/A N/A telnetlib Telnet public_ip port N/A N/A valid_object port port N/A N/A N/A valid_object port 22 N/A N/A N/A valid_object configured False N/A N/A valid_object user root N/A N/A N/A valid_object configured True N/A N/A valid_object user N/A N/A getpass getuser N/A N/A valid_object host_string N/A N/A {0}:{1} format public_ip port N/A valid_object N/A __set_unconfigured_servers N/A N/A N/A N/A N/A N/A env unconfigured_servers N/A N/A server N/A env bootmachine_servers N/A N/A N/A N/A server port N/A int N/A settings SSH_PORT N/A N/A N/A N/A N/A env unconfigured_servers append server N/A N/A N/A N/A N/A N/A logging getLogger paramiko setLevel N/A logging DEBUG