def list_running():
    ret = []
    for line in _machinectl('list')['stdout'].splitlines():
        try:
            ret.append(line.split()[0])
        except IndexError:
            pass
    return sorted(ret)

# 'machinectl list' shows only running containers, so allow this to work as an
# alias to nspawn.list_running
Lists running nspawn containers
dataset/ETHPy150Open saltstack/salt/salt/modules/nspawn.py/list_running