AWS EC2 に Selenium 環境作った メモ

下記を参考に構築
qiita.com

> sudo su -
# curl https://intoli.com/install-google-chrome.sh | bash

Successfully installed google-chrome-stable, Google Chrome 72.0.3626.109 .
途中 エラーが出ても気にしない...

# vim /etc/yum.repos.d/centos.repo

[CentOS-base]
name=CentOS-6 - Base
mirrorlist=http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=os
gpgcheck=1
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

#released updates
[CentOS-updates]
name=CentOS-6 - Updates
mirrorlist=http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=updates
gpgcheck=1
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

#additional packages that may be useful
[CentOS-extras]
name=CentOS-6 - Extras
mirrorlist=http://mirrorlist.centos.org/?release=6&arch=x86_64&repo=extras
gpgcheck=1
gpgkey=http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6

# rpm --import http://mirror.centos.org/centos/RPM-GPG-KEY-CentOS-6
# yum -y install GConf2

以下から  Google Chrome のバージョンにあう ChromeDriver のバージョンをダウンロード
https://sites.google.com/a/chromium.org/chromedriver/downloads

# wget https://chromedriver.storage.googleapis.com/2.46/chromedriver_linux64.zip
# unzip chromedriver_linux64.zip
# mv chromedriver /usr/local/bin

# wget https://noto-website-2.storage.googleapis.com/pkgs/Noto-hinted.zip
# unzip Noto-hinted.zip
# mkdir -p /usr/share/fonts/opentype/noto
# cp *otf *ttf /usr/share/fonts/opentype/noto
# fc-cache -f -v # optional

>conda install selenium