예제 #1
0
파일: dvsdk.py 프로젝트: muravjov/disvolvu
def docker_action(tgt_name, keyfile, image, **kwargs):
    def on_action():
        import setup_container
        res = bool(setup_container.find_container(tgt_name, search_all=True))

        if not res:
            setup_container.setup(tgt_name, keyfile, image, **kwargs)

    source = "dvsdk_sshpass"

    global sshpass_installed
    if not sshpass_installed:
        apt_action(source, "sshpass")
        sshpass_installed = True
    disvolvu.append_edge(tgt_name, [source], action=on_action)
예제 #2
0
파일: dvsdk.py 프로젝트: muravjov/disvolvu
def docker_action(tgt_name, keyfile, image, **kwargs):
    def on_action():
        import setup_container

        res = bool(setup_container.find_container(tgt_name, search_all=True))

        if not res:
            setup_container.setup(tgt_name, keyfile, image, **kwargs)

    source = "dvsdk_sshpass"

    global sshpass_installed
    if not sshpass_installed:
        apt_action(source, "sshpass")
        sshpass_installed = True
    disvolvu.append_edge(tgt_name, [source], action=on_action)
예제 #3
0
파일: dvsdk.py 프로젝트: muravjov/disvolvu
def ansible_action(tgt_name, sources, module_name, **kwargs):
    def on_action():
        return ansible_action_impl(module_name, **kwargs)

    disvolvu.append_edge(tgt_name, sources=sources, action=on_action)
예제 #4
0
파일: dvsdk.py 프로젝트: muravjov/disvolvu
def ansible_action(tgt_name, sources, module_name, **kwargs):
    def on_action():
        return ansible_action_impl(module_name, **kwargs)

    disvolvu.append_edge(tgt_name, sources=sources, action=on_action)