title: Attach xterm.js to Docker container
body: <p>I'm trying to add a terminal to a web application with xterm.js and its 'attach' addon.  I'd like to just have a process running in a Docker container, and then attach the xterm instance to stdin/stdout for the container.  The <a href="https://xtermjs.org/docs/api/addons/attach/" rel="nofollow noreferrer">example for the attach addon</a> indicates that this should be straightforward using the websocket interface for container attachment with docker.  </p>
  
  <p>I haven't yet been able to do this successfully, but it's possible that it's purely a problem with my local configuration.  A <a href="https://github.com/xtermjs/xterm.js/issues/883" rel="nofollow noreferrer">github issue for xterm.js</a> leaves it a bit ambiguous whether this should actually work now, based on changes to the docker API.  Has anyone had success with this using a modern version of docker?</p>