Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

level="fatal" msg="cannot enable tty mode on non tty input" #913

Closed
pdxbmw opened this issue Jan 21, 2015 · 4 comments

Comments

Projects
None yet
2 participants
@pdxbmw
Copy link

commented Jan 21, 2015

The dokku run command executes the docker run command in interactive mode, which causes remote commands to terminate with the error:

level="fatal" msg="cannot enable tty mode on non tty input"

(I was trying to setup a cronjob to run nightly). The only way I could get this to work was to manually execute docker run without the -i switch instead of executing dokku run.

Cronjob:

Doesn't work:
0 15 * * * bash -c ': | PATH="$PATH:/usr/local/bin" dokku run www python main.py' > /tmp/main.output
Works:
0 15 * * * bash -c ': | PATH="$PATH:/usr/local/bin" docker run -t dokku/www /exec python main.py' > /tmp/main.output

@michaelshobbs

This comment has been minimized.

Copy link
Member

commented Jan 21, 2015

Perhaps related to #552 or new in the latest docker version. Not sure of the right solution here. Perhaps we can detect when we have a TTY and pass -i or not.

@pdxbmw

This comment has been minimized.

Copy link
Author

commented Jan 21, 2015

Hmm, the only reference I see in the Docker release notes is back in version 1.3.1, but it's not clear to me what they fixed. For what it's worth, my first cronjob command worked before I upgraded Dokku (I believe I was on 0.2.0).

@michaelshobbs

This comment has been minimized.

Copy link
Member

commented Jan 21, 2015

@pdxbmw #914 seems to solve your issue. can you confirm?

@pdxbmw

This comment has been minimized.

Copy link
Author

commented Jan 21, 2015

Yes, I resorted back to my original command and it worked perfectly.

michaelshobbs added a commit that referenced this issue Jan 22, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.