dj2 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/lib/image_helper.rb +11 -7
  3. data/lib/version.rb +1 -1
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2abcd8f7f5dbd7df21a2cc8f6afbee66ebb88abb
4
- data.tar.gz: 5f215f25396609743e4323ffcda13ed87dc4eb6f
3
+ metadata.gz: 848d73295a98c6a439b77567d6438522cd65afa4
4
+ data.tar.gz: b7dc9b3d1de37fb2f085fa614eea56625f615a65
5
5
  SHA512:
6
- metadata.gz: 48ed4c58caed77c642ec2af36090b14d4cede579ab75be28017a05dc39ac7919040d60a4422d6433351c45a75877cfd310e9ad1fc7b0c2707e54be2d40fc4ffd
7
- data.tar.gz: f77a310deffca7ec6b71f6746195fbdf608902e7261f1152f2534da558a3f3e5d1701d38829d8a3f10b46287b8399360b53f7836bd875431c3ca15e5109f31e2
6
+ metadata.gz: 5aa38d258eeee87fb43663c46110964c2b37778ec4985dc34f9600e5550d2d08db91260959bb5b141cff7d08af13ee3820f07f7c02bb09b5c442cb67a4b65c5a
7
+ data.tar.gz: 110aa2269af8cfd1643192aca62513f394f00a91470b8ccbb217e1383aaba2927ab2af2f9627b7925e0aebca5991b495152920a46023ae981b46261ec8126a3b
@@ -8,12 +8,14 @@ module DockerJockey
8
8
  end
9
9
  image_name = args[0]
10
10
  filename = args[1]
11
- FileUtils.mkdir_p '/tmp/app'
12
- DockerJockey.exec("cp -r . /tmp/app")
11
+ # tmpdir = 'tmp/app'
12
+ # FileUtils.mkdir_p tmpdir
13
+ # DockerJockey.exec("cp -r . #{tmpdir}")
13
14
  entrypoint = [entry]
14
15
  entrypoint << filename if filename
15
16
  # exec("cp /scripts/lib/Dockerfile /tmp/app")
16
- File.open('/tmp/app/Dockerfile', 'w') { |file|
17
+ dockerfile = "__Dockerfile__"
18
+ File.open(dockerfile, 'w') { |file|
17
19
  file.write("FROM #{from}
18
20
  WORKDIR /app
19
21
  COPY . /app/
@@ -22,10 +24,12 @@ module DockerJockey
22
24
  }
23
25
  # DockerJockey.exec("cat /tmp/app/Dockerfile")
24
26
  # DockerJockey.exec("ls -al /tmp/app")
25
- FileUtils.cd('/tmp/app') do
26
- DockerJockey.exec("/usr/bin/docker version")
27
- DockerJockey.exec("/usr/bin/docker build -t #{image_name} .")
28
- end
27
+ # FileUtils.cd(tmpdir) do
28
+ DockerJockey.exec("docker version")
29
+ DockerJockey.exec("docker build -t #{image_name} -f #{dockerfile} .")
30
+ # end
31
+ File.delete(dockerfile)
32
+
29
33
  end
30
34
  end
31
35
  end
@@ -1,3 +1,3 @@
1
1
  module DockerJockey
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dj2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Travis Reeder