dockerfile制作:制作python3下的robotframework运行环境
【摘要】
dockerfile制作,制作python3下的robotframework运行环境
FROM centos:7.6.1810 MAINTAINER The Ecs Automation Project testops_xxx@163.comENV PATH $PATH:/usr/local/python3/bin/ENV P...
dockerfile制作,制作python3下的robotframework运行环境
-
FROM centos:7.6.1810
-
-
MAINTAINER The Ecs Automation Project testops_xxx@163.com
-
ENV PATH $PATH:/usr/local/python3/bin/
-
ENV PYTHONIOENCODING utf-8
-
RUN set -ex
-
&& mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup
-
&& curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
-
&& yum makecache
-
&& sed -i -e '/mirrors.cloud.aliyuncs.com/d' -e '/mirrors.aliyuncs.com/d' /etc/yum.repos.d/CentOS-Base.repo
-
&& yum -y install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gcc make wget
-
&& yum clean all
-
&& mkdir /usr/local/python3
-
&& wget https://www.python.org/ftp/python/3.6.8/Python-3.6.8.tar.xz
-
&& tar -xvJf Python-3.6.8.tar.xz && rm -f Python-3.6.8.tar.xz
-
&& cd Python-3.6.8
-
&& ./configure prefix=/usr/local/python3
-
&& make && make install
-
&& cd ..
-
&& pip3 --default-timeout=1000 install --upgrade pip -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
-
&& pip3 --default-timeout=1000 install --upgrade setuptools -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
-
&& pip3 --default-timeout=1000 install robotframework-selenium2library -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
-
&& pip3 --default-timeout=1000 install robotframework -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
-
&& pip3 --default-timeout=1000 install robotframework-ride==1.5.2.1 -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
-
&& && pip3 --default-timeout=1000 install pyvirtualdisplay -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
-
&& pip3 --default-timeout=1000 install robotframework-pabot -i http://pypi.douban.com/simple --trusted-host pypi.douban.com
-
&& cd /etc/yum.repos.d/
-
&& yum -y install firefox
-
&& firefox --version
-
RUN wget https://github.com/mozilla/geckodriver/releases/download/v0.24.0/geckodriver-v0.24.0-linux64.tar.gz
-
&& tar -zxf geckodriver-v0.24.0-linux64.tar.gz
-
&& mv geckodriver /usr/local/bin
-
&& firefox --version
-
&& cd /etc/
-
&& echo "106.11.210.201 g.alicdn.com" >> hosts
-
&& echo "100.67.79.188 ecs-buy.aliyun.com" >> hosts
-
&& echo "100.67.79.188 eci.console.aliyun.com" >> hosts
-
&& echo "100.67.79.188 ecs.console.aliyun.com" >> hosts
-
-
RUN yum -y update
-
&& yum -y install httpd
-
&& yum -y install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gcc make wget
-
&& wget --no-check-certificate --no-cookies --header "Cookie: oraclelicense=accept-securebackup-cookie" http://download.oracle.com/otn-pub/java/jdk/8u131-b11/d54c1d3a095b4ff2b6607d096fa80163/jdk-8u131-linux-x64.rpm
-
&& chmod +x jdk-8u131-linux-x64.rpm
-
&& rpm -ivh jdk-8u131-linux-x64.rpm
-
CMD ["usr","bin","bash"]
文章来源: blog.csdn.net,作者:懿曲折扇情,版权归原作者所有,如需转载,请联系作者。
原文链接:blog.csdn.net/qq_41332844/article/details/126837478
【版权声明】本文为华为云社区用户转载文章,如果您发现本社区中有涉嫌抄袭的内容,欢迎发送邮件进行举报,并提供相关证据,一经查实,本社区将立刻删除涉嫌侵权内容,举报邮箱:
cloudbbs@huaweicloud.com
- 点赞
- 收藏
- 关注作者
评论(0)