Docker和Github集成- Github文件去哪里了?



我正在尝试docker和github的集成。

我现在所做的是在我的存储库中放置一个Dockerfile: https://github.com/mxlei01/YouTube-Channel-Search.

暂时忽略git clone命令,我试过:

docker pull mxlei01/youtube-channel-search
docker images (to find all the images)
docker run mxlei01/youtube-channel-search

但是,当我试图使用export:

提取文件时
docker ps -a
docker export <container ID> > file.tar
tar -xvf file.tar

我无法找到我的任何文件在我的git仓库使用命令:

find . -name "mongo.py"

所以我添加了一个命令来手动获取项目,然而,我不认为这是正确的方式,然而,它可能是可行的。

谁能给我指个正确的方向?

感谢

--------- 编辑 ----------

你可以像这样复制:

RUN mkdir /application
COPY Tornado-Application /application/Tornado-Application

你的Dockerfile是:

FROM buildpack-deps:wheezy
#Create a folder, and git pull the repo
RUN mkdir /application

它将创建/application文件夹,但不会复制其中的任何内容。
至少需要一些COPY指令来将GitHub项目的其他文件夹包含在图像中。

最新更新