- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
docker compose将保留旧卷,现在无法清除它们
我试图将当前目录挂载到容器中,
并多次更改其挂载名称,
像crawler
-> data-crowler
-> ... root
但是,一旦我挂载它,即使我更改了mount volume name
,它也将保留在容器中
有趣的是,我从未使用USER seluser
做任何事情,
但是您可以看到文件夹的所有者是seluser
那怎么会发生呢?
Dockerfile的结尾
EXPOSE 4444
WORKDIR /lazy-bird
CMD ["/usr/bin/supervisord"]
web:
build: .
volumes:
- .:/lazy-bird
drwxrwxr-x 6 seluser seluser 4.0K Jun 10 02:39 crawler/
drwxrwxr-x 6 seluser seluser 4.0K Jun 10 02:39 data-crowler/
drwxrwxr-x 6 seluser seluser 4.0K Jun 10 02:39 lazy-bird/
drwxrwxr-x 6 seluser seluser 4.0K Jun 10 02:39 root/
FROM selenium/node-firefox-debug
USER root
RUN apt-get update -qqy \
&& apt-get -qqy --no-install-recommends install \
firefox supervisor cron\
rsyslog \
&& rm -rf /var/lib/apt/lists/*
COPY config.json /opt/selenium/config.json
RUN apt-get update && apt-get -y upgrade && apt-get -y -qq --force-yes install \
build-essential \
tree \
ruby-dev \
vim \
git \
curl \
zsh \
sudo
# Install dependencies packages
RUN apt-get update && apt-get install -y \
build-essential \
openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev \
libssl-dev libyaml-dev libsqlite3-dev sqlite3 libxml2-dev libxslt-dev \
autoconf libc6-dev ncurses-dev automake libtool bison nodejs
# Install Zsh
################## BEGIN INSTALLATION ######################
RUN git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh \
&& cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc \
&& chsh -s /bin/zsh
RUN sed -i -E "s/^plugins=\((.*)\)$/plugins=(\1 git git-flow ruby )/" ~/.zshrc
RUN echo "export TERM=vt100" >> /etc/zsh/zshrc
# bindkey to make HOME/END works on zsh shell
# set term=xtern make HOME/END works in vim
RUN echo "alias ls='ls --color=auto'" >> /etc/zsh/zshrc && \
echo "alias ll='ls -halF'" >> /etc/zsh/zshrc && \
echo "bindkey -v" >> /etc/zsh/zshrc && \
echo "bindkey '\eOH' beginning-of-line" >> /etc/zsh/zshrc && \
echo "bindkey '\eOF' end-of-line" >> /etc/zsh/zshrc && \
echo "alias ls='ls --color=auto'" >> /etc/profile &&\
echo "set term=xterm" >> ~/.vimrc
WORKDIR /tmp
COPY Gemfile Gemfile
RUN gem install bundler
RUN bundle install
#====================================
# Scripts to run cron job
#====================================
#ADD cron_lazy_bird /etc/crontab
RUN touch /var/log/cron.log
#====================================
# Scripts to run Selenium Standalone
#====================================
EXPOSE 4444
#USER root
# The following must match to docker-compose.yml or the container can not launch
WORKDIR /lazy-bird
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
CMD ["/usr/bin/supervisord"]
#!/bin/bash
export GEOMETRY="$SCREEN_WIDTH""x""$SCREEN_HEIGHT""x""$SCREEN_DEPTH"
xvfb-run --server-args="$DISPLAY -screen 0 $GEOMETRY -ac +extension RANDR" \
java -jar /opt/selenium/selenium-server-standalone.jar \
-role node \
-hub http://$HUB_1_PORT_4444_TCP_ADDR:$HUB_1_PORT_4444_TCP_PORT/grid/register \
-browser browserName=firefox
--background
最佳答案
回答您的问题之一:
What the interest is I've never use USER seluser to do anything,
But you can see the folder's owner is seluser
How could that happened ?
USER seluser
涉及镜像的时间
core@core-01 ~ $ docker pull centurylink/dockerfile-from-image
core@core-01 ~ $ alias dimages="docker run -v /var/run/docker.sock:/var/run/docker.sock centurylink/dockerfile-from-image"
core@core-01 ~ $ dimages selenium/node-firefox-debug
ADD file:b43bf069650bac07b66289f35bfdaf474b6b45cac843230a69391a3ee342a273 in /
RUN echo '#!/bin/sh' > /usr/sbin/policy-rc.d && echo 'exit 101' >> /usr/sbin/policy-rc.d && chmod +x /usr/sbin/policy-rc.d && dpkg-divert --local --rename --add /sbin/initctl && cp -a /usr/sbin/policy-rc.d /sbin/initctl && sed -i 's/^exit.*/exit 0/' /sbin/initctl && echo 'force-unsafe-io' > /etc/dpkg/dpkg.cfg.d/docker-apt-speedup && echo 'DPkg::Post-Invoke { "rm -f /var/cache/apt/archives/*.deb /var/cache/apt/archives/partial/*.deb /var/cache/apt/*.bin || true"; };' > /etc/apt/apt.conf.d/docker-clean && echo 'APT::Update::Post-Invoke { "rm -f /var/cache/apt/archives/*.deb /var/cache/apt/archives/partial/*.deb /var/cache/apt/*.bin || true"; };' >> /etc/apt/apt.conf.d/docker-clean && echo 'Dir::Cache::pkgcache ""; Dir::Cache::srcpkgcache "";' >> /etc/apt/apt.conf.d/docker-clean && echo 'Acquire::Languages "none";' > /etc/apt/apt.conf.d/docker-no-languages && echo 'Acquire::GzipIndexes "true"; Acquire::CompressionTypes::Order:: "gz";' > /etc/apt/apt.conf.d/docker-gzip-indexes
RUN sed -i 's/^#\s*\(deb.*universe\)$/\1/g' /etc/apt/sources.list
CMD ["/bin/bash"]
MAINTAINER Selenium <selenium-developers@googlegroups.com>
RUN echo "deb http://archive.ubuntu.com/ubuntu trusty main universe\n" > /etc/apt/sources.list && echo "deb http://archive.ubuntu.com/ubuntu trusty-updates main universe\n" >> /etc/apt/sources.list
RUN apt-get update -qqy && apt-get -qqy --no-install-recommends install ca-certificates openjdk-7-jre-headless unzip wget && rm -rf /var/lib/apt/lists/* && sed -i 's/\/dev\/urandom/\/dev\/.\/urandom/' ./usr/lib/jvm/java-7-openjdk-amd64/jre/lib/security/java.security
RUN mkdir -p /opt/selenium && wget --no-verbose http://selenium-release.storage.googleapis.com/2.46/selenium-server-standalone-2.46.0.jar -O /opt/selenium/selenium-server-standalone.jar
RUN sudo useradd seluser --shell /bin/bash --create-home && sudo usermod -a -G sudo seluser && echo 'ALL ALL = (ALL) NOPASSWD: ALL' >> /etc/sudoers && echo 'seluser:secret' | chpasswd
MAINTAINER Selenium <selenium-developers@googlegroups.com>
ENV DEBIAN_FRONTEND=noninteractive
ENV DEBCONF_NONINTERACTIVE_SEEN=true
ENV TZ=US/Pacific
RUN echo "US/Pacific" | sudo tee /etc/timezone && dpkg-reconfigure --frontend noninteractive tzdata
RUN apt-get update -qqy && apt-get -qqy install xvfb && rm -rf /var/lib/apt/lists/*
COPY file:335d2f6f9bfe311d2b38034ceab3b2ae2a1e07b9b203b330cac9857d6e17c148 in /opt/bin/entry_point.sh
RUN chmod +x /opt/bin/entry_point.sh
ENV SCREEN_WIDTH=1360
ENV SCREEN_HEIGHT=1020
ENV SCREEN_DEPTH=24
ENV DISPLAY=:99.0
USER [seluser]
CMD ["/opt/bin/entry_point.sh"]
MAINTAINER Selenium <selenium-developers@googlegroups.com>
USER [root]
RUN apt-get update -qqy && apt-get -qqy --no-install-recommends install firefox && rm -rf /var/lib/apt/lists/*
COPY file:52a2a815e3bb6b85c5adfbceaabb5665b63f63ef0fb0e3f774624ee399415f84 in /opt/selenium/config.json
USER [seluser]
MAINTAINER Selenium <selenium-developers@googlegroups.com>
USER [root]
RUN apt-get update -qqy && apt-get -qqy install x11vnc && rm -rf /var/lib/apt/lists/* && mkdir -p ~/.vnc && x11vnc -storepasswd secret ~/.vnc/passwd
ENV LANGUAGE=en_US.UTF-8
ENV LANG=en_US.UTF-8
RUN locale-gen en_US.UTF-8 && dpkg-reconfigure --frontend noninteractive locales && apt-get update -qqy && apt-get -qqy --no-install-recommends install language-pack-en && rm -rf /var/lib/apt/lists/*
RUN apt-get update -qqy && apt-get -qqy --no-install-recommends install fonts-ipafont-gothic xfonts-100dpi xfonts-75dpi xfonts-cyrillic xfonts-scalable && rm -rf /var/lib/apt/lists/*
RUN apt-get update -qqy && apt-get -qqy install fluxbox && rm -rf /var/lib/apt/lists/*
COPY file:90e3a7f757c3df44d541b59234ad4ca996f799455eb8d426218619b244ebba68 in /opt/bin/entry_point.sh
RUN chmod +x /opt/bin/entry_point.sh
EXPOSE 5900/tcp
关于docker - docker compose将保留旧卷,现在无法清除它们,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30770537/
几周前,我安装了一个新的 ssl 证书来替换一个过期的证书。 .crt 和 .key 的文件名保持不变。只是内容变了。 现在,当我访问我的网站时,它说证书已过期,我看到它正在使用旧的证书链。我可以确认
这个问题在这里已经有了答案: Make namespaces backwards compatible in PHP (4 个回答) 8 年前关闭。 我真的很想在我的工作流程中采用命名空间。据我了解,
我从 CN1 开始,然后以 Todo App 为例。当我在 Netbeans 中运行 de app 时,只出现一个空白表单,我更改了主题,添加了一个 jpg 图像并使用旧的 GUI Builder 在
我想知道是否有一些 Laravel 人员可以帮忙。 我有一个表单,其中有 2 个单选按钮,当表单提交时,它会通过验证器,如果验证器失败,它会返回表单,使用输入填充字段并显示错误消息。 我似乎无法对单选
我正在使用 Java 中没有泛型的旧代码。 hashMap 是在该代码中定义的,没有泛型,例如: Map A = new HashMap(); 在这段代码中,我想如何确定要在键和值中放入什么内容,以及
我想问一个关于项目兼容性的问题。我的论文项目是在Windows Vista和XP上在JRE 1.6和JDK 1.6下开发的。该项目使用Java新套接字。今天我尝试在 Windows 8(64 位)机器
有谁知道一个脚本可以将旧的 Products 命名空间样式 Plone 附加组件包装到 Egg 中吗? 生成setup.py 创建目录结构 还需要采取其他措施吗? 鸡蛋化过程中有什么陷阱吗? 最佳答案
我已经运行 MySQL 5.6.12 一段时间了。我决定将我的 WAMP 服务器更新到最新的 PHP 版本。 在此过程中,它还将 MySQL 更新到 5.6.17,保留 .12 数据,但无法访问。 如
最近,我一直在尝试根据互联网上的各种旧教程编写论坛代码,但是我最近遇到了一个问题 - 尽管我完全按照教程所述进行操作,但我收到了空格错误。我认为这可能是因为某些 MySQL 命令可能已更改。如果有人可
我正在创建对 Count 表的查询。 $Month = $_POST['Month']; $query = "SELECT ANY_VALUE(AD) AS ad, COU
如果我使用 mysqldump 工具备份旧版本的 MySql 数据库,是否存在任何已知风险?例如,如果我在生产机器上使用 mysqldump 5.6 来备份 MySql 5.X 数据库。 最佳答案 有
当将 columnsData 值分配给 columns 时,我有两个 JSON 对象 columnsData 和 columns,这两个值都会更改。 var columnsData = [
我有一个需要在 gcc 4.4 上编译的多线程应用程序,我不允许使用 c++0x 标志。 我希望一个变量以原子方式运行,但不幸的是没有 C++0x 标志我无法使用 atomic在 C++ 中。 我试过
我可以借助广播事件(ACTION_TIME_CHANGED 和 ACTION_DATE_CHANGED)获取时间更改事件。 我需要在时间更改后获取之前的时间。例如,当前时间是 10:00。我要把时间改
我正在尝试在我的 Android 应用程序中创建一个 DatePickerDialog,但是当我创建一个 DatePickerDialog 时,我收到以下消息:Call requires API le
{!! Form::open(array('route' => 'posts.store', 'data-parsley-validate' => '')) !!} {{ Form::labe
我的问题与 iOS 周围的蓝牙技术有关。我看过关于蓝牙低功耗 101、新功能、基础知识等的 WWDC,以及关于使用 iOS 5 及更高版本中可用的 CoreBluetooth 框架的内容。我浏览了不同
我有一个有五个屏幕的应用。 在每个屏幕上,我在 viewDidLoad 中从服务器访问数据。 在每个屏幕上我都有下一个按钮。 当我从屏幕一转到屏幕五(通过单击下一步 4 次)时,在 NSLog 中,我
我最近在一家网络报纸找到了一份工作。在网站上,我们有一个非常古老且重要的 Symfony 应用程序,它是为一位年长的开发人员编写的,已经消失很久了。该应用程序是神圣的:是报纸收入的血液。问题是我们没有
我相信我已经找到了一种方法来实现类似可移植 C89 中众所周知的“struct hack”的方法。我很好奇这是否真的严格符合 C89。 主要思想是:我分配足够大的内存来容纳初始结构和数组元素。确切的大
我是一名优秀的程序员,十分优秀!