6
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

crontabでdocker-compose execを実行すると"the input device is not a TTY"が出る

Posted at

解決策

-Tのオプションを使う

問題があった時の設定

0 4 * * * docker-compose exec {container_name} {some_command}

解決後の設定

0 4 * * * docker-compose exec -T {container_name} {some_command}

原因

よくはわかっていないが、docker-compose execはデフォルトで擬似ttyが割り当てられてしまう。
それを解除するオプションが -Tとのこと。

-T
Disable pseudo-tty allocation. By default docker-compose execallocates a TTY.

参考

6
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?