Docker : How to run grunt-open?

I have been using a grunt-open package for open my browser when i build my project. Recently I begin to use docker and this works perfectly, But the grunt-open task don’t works anymore.

Exist some way to create a bridge between my docker and my local machine for opens my browser using grunt-open?

  • Is it possible to create container in multiple host using a single docker compose file?
  • How to install docker-engine using docker binary without internet connection
  • Linux machine with docker deploy windows container
  • Not be able to log on to standard Neo4j Docker container - disable authentication form outside?
  • How do I set the AWS Autoscaler to use the same IP addresses?
  • Can we pass ENV variables through cmd line while building a docker image through dockerfile?
  • Dockerfile VOLUME definition to mount project tree
  • How to configure a Docker container for acquiring DHCP IP/s from dhcp server running on ESX
  • Create user in ubuntu docker instead using root
  • not able to access angular2 app from docker container
  • docker -v and symlinks
  • cant connect to docker daemon - eclipse che
  • 2 Solutions collect form web for “Docker : How to run grunt-open?”

    There is no way to open an external browser if you are running or building your project inside a docker container. The idea of using docker is to have all the tools you need inside the container.

    You can use an gui less browser like PhantomJS and run grunt-open task inside the docker container.

    There is no “automatic” way – you would need to have some kind of listener on your local machine. So you can’t really use grunt-open from the container but there are any number of ways you could have the grunt task in the container send a call to your local machine which could use grunt-open (or npm-open which it’s a wrapper for, or opn which npm-open is a wrapper for) — or a simple shell script.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.