Use docker-compose exec -T with ansible tasks

Docker-compose exec allocates a tty by default unlike docker exec. New
Ansible doesn't provision a tty which causes docker-compose exec to fail
under Ansible now. Address this by passing -T to docker-compose exec
commands which stops allocating a tty. We didn't need one to gracefully
stop zuul services.

Change-Id: Ib52f184f771ae4530f6b6531257dda5d8443043c
This commit is contained in:
Clark Boylan 2022-12-12 08:03:19 -08:00
parent 6ba64f1d6e
commit 46ba1ff961
2 changed files with 2 additions and 2 deletions

View File

@ -9,7 +9,7 @@
register: executor_container_list
- name: Gracefully stop Zuul Executor
shell:
cmd: docker-compose exec executor zuul-executor graceful
cmd: docker-compose exec -T executor zuul-executor graceful
chdir: /etc/zuul-executor
become: true
become_user: root

View File

@ -9,7 +9,7 @@
register: merger_container_list
- name: Gracefully stop Zuul Merger
shell:
cmd: docker-compose exec merger zuul-merger stop
cmd: docker-compose exec -T merger zuul-merger stop
chdir: /etc/zuul-merger
become: true
become_user: root