从流浪汉建立一个码头图像

时间:2015-06-01 12:43:49

标签: docker vagrant

我想从Vagrant容器构建一个Docker镜像。 流浪汉的环境运作没有任何问题。

我创建了一个Dockerfile:

touch Dockerfile

我在Vagrant机器目录中创建了myapp目录(我不确定是否应该这样做):

mkdir myapp

我将这些行添加到Vagrantfile:

  config.vm.provision "docker" do |docker|
    docker.build_image "/vagrant/myapp"
  end

我遇到了这个错误:

The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!

docker build  /vagrant/myapp

Stdout from the command:



Stderr from the command:

stdin: is not a tty
time="2015-06-01T12:34:44Z" level=fatal msg="Cannot locate Dockerfile: Dockerfile" 

您认为我错过了什么?

更新

这是应用程序文件树:

.
├── Dockerfile
├── myapp/
└── Vagrantfile

0 个答案:

没有答案