Skip to content

Instantly share code, notes, and snippets.

@fujin
Created March 30, 2017 19:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fujin/185665a555d1dd3804f11bc5edbb1a23 to your computer and use it in GitHub Desktop.
Save fujin/185665a555d1dd3804f11bc5edbb1a23 to your computer and use it in GitHub Desktop.
Docker + Xvfb + Chrome + protractor/karma
browsers: ['Chrome_no_sandbox'],
customLaunchers: {
Chrome_no_sandbox: {
base: 'Chrome',
flags: ['--no-sandbox']
}
},
capabilities: {
'browserName': 'chrome',
'chromeOptions': {
'args': ['no-sandbox']
}
},
#!/bin/bash
set -xeo pipefail
export DISPLAY=:99.0
export CHROME_BIN=/usr/bin/chromium
install_packages chromium xvfb
Xvfb :99 -ac -screen 0 1280x720x16 -nolisten tcp &
npm install
npm test
npm cache clean
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment