官方Selenium Hub docker镜像的自定义返回“权限被拒绝”
我从这里复制官方selenium网格枢纽的dockerfile。
我想定制它的configuration文件,所以不是复制[复制]他们,我添加他们[添加]的url。
所以这:
COPY generate_config /opt/selenium/generate_config COPY entry_point.sh /opt/bin/entry_point.sh
变成这样:
ADD https://gist.githubusercontent.com/myaccount/d5203b3e/raw/d8dfcd9fd/generate_config /opt/selenium/generate_config ADD https://gist.githubusercontent.com/myaccount/gfsfe2fc/raw/fdefe4e06/entry_point.sh /opt/bin/entry_point.sh
我在Win10上使用Docker-Toolbox,在Kitematic里面我看到:
难道我做错了什么?
我错过了什么吗?
这与操作系统的差异有关吗?
dockerfile的目的不是为了构build跨平台的图像吗?
-EDIT-另外…与selenium网格node-firefox dockerfile相关的事情发生。
从Kitematic我得到这个:
在ADD命令之后,您应该在Dockerfile中添加如下内容:
RUN chmod a+x /opt/bin/entry_point.sh \ && chmod a+x /opt/selenium/generate_config
这是因为使用COPY将文件添加到图像时,它们对主机(已保存)已具有执行权限,但使用ADD从远程源添加它们时,不会自动获得执行权限。