Linux Centos7安装chrome浏览器

  参考:https://blog.csdn.net/u010472499/article/details/72327963

  1. 配置yum源

  在目录 /etc/yum.repos.d/ 下新建文件 google-chrome.repo

  cd /ect/yum.repos.d/
  vim google-chrome.repo

  写入如下内容:

[google-chrome]
name=google-chrome
baseurl=http://dl.google.com/linux/chrome/rpm/stable/$basearch
enabled=1
gpgcheck=1
gpgkey=https://dl-ssl.google.com/linux/linux_signing_key.pub

 

   安装google chrome浏览器:

   yum -y install google-chrome-stable

  Google官方源可能在中国无法使用,导致安装失败或者在国内无法更新,可以添加以下参数来安装:

  yum -y install google-chrome-stable --nogpgcheck

  运行chrome 
  找到chrome路径,并做个软连接,方便使用:

  which google-chrome-stable
  ln -s xxx /bin/chrome

  使用root用户启动chrome示例时会提示添加参数–no-sandbox flag

  chrome --no-sandbox flag
posted on 2018-06-13 16:07  shaomine  阅读(4438)  评论(0编辑  收藏  举报