specinfra 2.54.0 → 2.54.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 42c69bf1bcc72e23216971401e677922ecdf0aac
4
- data.tar.gz: 98600b6e95e8e98aa430e97969f8a386fd1d31c8
3
+ metadata.gz: 6fa60eb46a20447f407f6f5a416c1174b8166f64
4
+ data.tar.gz: 0e07b23d495aa0de72169b951f5eba45855a2805
5
5
  SHA512:
6
- metadata.gz: 6e8bdcaf0fb9cf61ac4d32f8e169d0f4a7365ba67042f4b618f436c7152992c1086482ecf84d3ab8558f662af442c11b2f717e358c93caae9f31f32dac277cf5
7
- data.tar.gz: fe2d437ce31175eabca75965e2816cca5496d51ef1877f0b04dc3aa37c12e78aeca4ec11058535abf9bd39f235613aae807f0953cff047b2d29cca5c20ff19f6
6
+ metadata.gz: 9e89e34be384b6940fa751e7c1909d6d44464b910fb7533cd12a1dac2b54b1ef84265715a0962ba45a339066d0e470fe0a750a9516a6cfb1a388169d31f4e21e
7
+ data.tar.gz: 920849864d28ab8000be8afa884ec24ba2bfcc7c82d392e9038ad59fd0ba41800e32913b49854dc402ba20962036d9d9083d223cc234f1cf02637a693a844e94
@@ -40,14 +40,17 @@ module Specinfra
40
40
  end
41
41
 
42
42
  def send_file(from, to)
43
- if @base_image.nil?
44
- fail 'Cannot call send_file without docker_image.'
43
+ if @base_image
44
+ @images << commit_container if @container
45
+ @images << current_image.insert_local('localPath' => from, 'outputPath' => to)
46
+ cleanup_container
47
+ create_and_start_container
48
+ elsif @container
49
+ # This needs Docker >= 1.8
50
+ @container.archive_in(from, to)
51
+ else
52
+ fail 'Cannot call send_file without docker_image or docker_container.'
45
53
  end
46
-
47
- @images << commit_container if @container
48
- @images << current_image.insert_local('localPath' => from, 'outputPath' => to)
49
- cleanup_container
50
- create_and_start_container
51
54
  end
52
55
 
53
56
  def commit_container
@@ -1,3 +1,3 @@
1
1
  module Specinfra
2
- VERSION = "2.54.0"
2
+ VERSION = "2.54.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: specinfra
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.54.0
4
+ version: 2.54.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gosuke Miyashita
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-20 00:00:00.000000000 Z
11
+ date: 2016-03-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: net-scp