title: Configuring Nightwatch to run tests on a standalone instance of Chrome
body: <p>I am trying to setup Nightwatch so that I do not have to use Selenium and instead point directly to an instance of Chrome on Linux, but I seem to be unable to connect to the chromedriver instance.</p>
  
  <h2>nightwatch.json</h2>
  
  <pre><code>{
    "src_folders" : ["tests"],
    "output_folder" : "reports",
    "custom_commands_path" : "",
    "custom_assertions_path" : "",
    "page_objects_path" : "",
    "globals_path" : "globals.js",
  
    "selenium" : {
      "start_process" : false,
      "cli_args" : {
        "webdriver.chrome.driver" : "./chromedriver"
      }
    },
  
    "test_settings" : {
      "default" : {
        "selenium_port"  : 9515,
        "selenium_host"  : "127.0.0.1",
        "silent": true,
        "screenshots" : {
          "enabled" : false,
          "path" : ""
        },
        "desiredCapabilities": {
          "browserName": "chrome",
      "acceptSslCerts": true
        }
      }
    }
  }
  </code></pre>
  
  <p>After attempting to run a simple test suite, I get the following error</p>
  
  <pre><code> ~/scripts/TestNightwatch$ nightwatch 
  
   [Test] Test Suite
   =====================
  
   Running:  Demo test Google Error processing the server response:  
   unknown command: wd/hub/session
  
   Error retrieving a new session from the selenium server
  
   Connection refused! Is selenium server started? { value: -1, error:
   'Unexpected token u in JSON at position 0' }
  </code></pre>
  
  <p>Have I not configured nightwatch properly to connect to Chrome? Am I missing any pieces of the puzzle?</p>
  
  <p>Thanks in advance!</p>
  
  <h2>globals.js</h2>
  
  <pre><code>var chromedriver = require('chromedriver');
  
  module.exports = {
    before : function(done) {
      chromedriver.start();
  
      done();
    },
  
    after : function(done) {
      chromedriver.stop();
  
      done();
    }
  }
  </code></pre>