(self, container_names=None, provisioning_mode=None)
Creates, starts and provisions the containers of the project.
Creates, starts and provisions the containers of the project.
Creates starts and provisions the containers of the project .
def up(self, container_names=None, provisioning_mode=None):
        """ Creates, starts and provisions the containers of the project. """
        containers = [self.get_container_by_name(name) for name in container_names] \
            if container_names else self.containers
        not_running = [c for c in containers if not c.is_running]
        if not not_running:
            logger.warning("Everything is already up and running! Nothing to do.")
            return
        [logger.info('Bringing container "{}" up'.format(c.name)) for c in not_running]
        for container in self._containers_generator(containers=not_running):
            container.up()
        self._update_guest_etchosts()

        # Provisions the container if applicable; that is only if it hasn't been provisioned before
        # or if the provisioning is manually enabled.
        provisioning_mode = provisioning_mode or constants.ProvisioningMode.AUTO
        if not provisioning_mode == constants.ProvisioningMode.DISABLED:
            force = provisioning_mode == constants.ProvisioningMode.ENABLED
            self.provision(container_names=[c.name for c in not_running], force=force)
def up ( self , container_names = None , provisioning_mode = None ) : containers = [ self . get_container_by_name ( name ) for name in container_names ] if container_names else self . containers not_running = [ c for c in containers if not c . is_running ] if not not_running : logger . warning ( "Everything is already up and running! Nothing to do." ) return [ logger . info ( 'Bringing container "{}" up' . format ( c . name ) ) for c in not_running ] for container in self . _containers_generator ( containers = not_running ) : container . up ( ) self . _update_guest_etchosts ( ) # Provisions the container if applicable; that is only if it hasn't been provisioned before # or if the provisioning is manually enabled. provisioning_mode = provisioning_mode or constants . ProvisioningMode . AUTO if not provisioning_mode == constants . ProvisioningMode . DISABLED : force = provisioning_mode == constants . ProvisioningMode . ENABLED self . provision ( container_names = [ c . name for c in not_running ] , force = force )