What is grunt serve capable of doing with connect?

374 views Asked by At

I am working on a project on a remote server since I need python and DB resources that my local machine can't access.

I've read this page a few times now: https://github.com/gruntjs/grunt-contrib-connect

... and can't find out what is meant by some of the terms.

In my Gruntfile.js I see:

// The actual grunt server settings
connect: {
  options: {
    port: 9000,
    // Change this to '0.0.0.0' to access the server from outside.
    hostname: 'localhost',
    livereload: 35729
  },

What exactly does "outside" mean? got it

What is "the server" referring to? got it

I am running grunt serve on a linux remote server and want to see my project livereload in my web browser. What URL should I use in the browser and what should the Gruntfile contain? Is this even possible?

When I run http://MyRemoteHostName:9000/ while using 0.0.0.0 as the hostname setting, the DNS address cannot be found.

Note that the apache web server/python code repository on my remote host is exposed to the web via another URL like http://special.development.url.com but this fails to show the app as well: http://special.development.url.com:9000

1

There are 1 answers

0
Quentin On

What exactly does "outside" mean?

A different computer.

The default is localhost which (unless you use some kind of port forwarding such as ssh tunnelling) can only be accessed from the computer it is running on. 0.0.0.0 means all the network interfaces in the computer (including any ethernet and wifi connections).

What is "the server" referring to?

The description of grunt-contrib-connect is Start a connect web server. That is the server it is talking about.