Last active
May 23, 2023 20:00
-
-
Save miztiik/60d8ba679d2668e2afd18b8a574a08d3 to your computer and use it in GitHub Desktop.
Script to setup headless Selenium (uses Xvfb & Firefox) in Redhat
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pip install selenium | |
pip install xvfbwrapper | |
yum install -y firefox | |
# Install the geckodriver | |
cd /tmp | |
curl -SO https://github.com/mozilla/geckodriver/releases/download/v0.11.1/geckodriver-v0.11.1-linux64.tar.gz | tar zxv - -C /usr/sbin | |
yum install -y xorg-x11-server-Xvfb | |
# yum install -y xorg-x11-Xvfb | |
# pip install pyvirtualdisplay | |
echo "Starting X virtual framebuffer (Xvfb) in background..." | |
Xvfb -ac :99 -screen 0 1280x1024x16 & | |
export DISPLAY=:99 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I have no idea, i was working on a experiment back then. Good Luck.