Skip to content

Instantly share code, notes, and snippets.

@withremote
Created November 19, 2015 18:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save withremote/61f5188da1cd90640131 to your computer and use it in GitHub Desktop.
Save withremote/61f5188da1cd90640131 to your computer and use it in GitHub Desktop.
Get Selenium and Firefox for headless testing in vagrant box
#!/usr/bin/env bash
# Get Selenium and Firefox for headless testing in vagrant box
if [ ! -d "/var/selenium" ]; then
sudo mkdir /var/selenium
cd /var/selenium
sudo wget http://goo.gl/PJUZfa selenium-server-standalone.jar
fi
sudo yum -y install java-1.8.0-openjdk-headless.x86_64
sudo yum -y install firefox.x86_64
sudo yum -y install xorg-x11-server-Xvfb.x86_64
# then add a alias to your bash profile
# alias sss='sudo DISPLAY=:1 xvfb-run java -jar /var/selenium/PJUZfa'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment