Skip to content

Conversation

@zhouhao3
Copy link

I try to set terminal to true. But it failed when testing.

failed to create the container
cannot allocate tty if runc will detach without setting console socket
exit status 1

Signed-off-by: Zhou Hao [email protected]

util.Fatal(err)
}

g.SetProcessConsoleSize(10, 80)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The spec says:

Runtimes MUST ignore consoleSize if terminal is false or unset.

which makes sense. We currently aren't testing that in runtimetest (and for validation/process.go the standard streams shouldn't be terminals anyway. So I don't have a problem setting consoleSize here, but if we actually want to test something by doing that we need to:

  • Setup our own pseudoterminal pair here with a different size and pass the slave in to create as stdin (at least).
  • Add tests to runtimetest to check that that, when consoleSize is false/unset, the actual console size does not match the config.json value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants