Opens the chrome browser in the ci job

parent 94171b21
......@@ -63,6 +63,7 @@ generate_previews:
- echo "deb http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list
- apt-get -y update
- apt-get -y install google-chrome-stable
- google-chrome --headless --hide-scrollbars --remote-debugging-port=9222 --disable-gpu --user-data-dir=remote-profile &
- export CHROME_BIN=`whereis google-chrome | cut -d " " -f 2`
- npm install
- cd dist
......
......@@ -98,7 +98,7 @@ class GenerateImages {
});
console.log('chrome stuff', CHROME_BIN, themePreviewEndpoint, params, path.join('ChromeDriver.js'), `--urls=${JSON.stringify(params)}`);
const chromeInstance = child_process.spawnSync(CHROME_BIN, flags);
// const chromeInstance = child_process.spawnSync(CHROME_BIN, flags);
const chromeDriver = child_process.spawn(`node`, [
path.join('ChromeDriver.js'), `--urls=${JSON.stringify(params)}`
]);
......@@ -111,7 +111,7 @@ class GenerateImages {
});
chromeDriver.on('exit', () => {
console.log(`ChromeDriver (exit): All preview images have been generated`);
chromeInstance.kill();
// chromeInstance.kill();
});
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment