Я пытался запустить docker-compose с помощью Fabric, но когда я запускал команду docker-compose up с помощью Fabric, я получил следующую ошибку:
[52577] Failed to execute script docker-compose
Traceback (most recent call last):
File "docker-compose", line 6, in <module>
File "compose/cli/main.py", line 71, in main
File "compose/cli/main.py", line 127, in perform_command
File "compose/cli/main.py", line 1080, in up
File "compose/cli/main.py", line 1076, in up
File "compose/project.py", line 475, in up
File "compose/service.py", line 352, in ensure_image_exists
File "compose/service.py", line 1217, in pull
File "compose/progress_stream.py", line 101, in get_digest_from_pull
File "compose/service.py", line 1182, in _do_pull
File "site-packages/docker/api/image.py", line 381, in pull
File "site-packages/docker/auth.py", line 48, in get_config_header
File "site-packages/docker/auth.py", line 96, in resolve_authconfig
File "site-packages/docker/auth.py", line 127, in _resolve_authconfig_credstore
File "site-packages/dockerpycreds/store.py", line 20, in __init__
File "site-packages/dockerpycreds/utils.py", line 12, in find_executable
File "distutils/spawn.py", line 176, in find_executable
File "os.py", line 669, in __getitem__
KeyError: 'PATH'
Failed to up the env
Когда я запускаю docker-compose изтерминал работает нормально.
@task
def up(c):
if c.run('docker-compose up', warn=True).failed:
print ("Failed to up the env")