rundock 1.1.2 → 1.1.3

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: 7879491846da01dd89f32447e3d005ff6a605a4d
4
- data.tar.gz: 9ca056e0dea037fc0d282c52425064558b14b7d7
3
+ metadata.gz: 427a5c5bf1af65355a3fd503eafb597c152db37e
4
+ data.tar.gz: 4d518a9ce6c376fe2b0fa18c5528c24927d6fac9
5
5
  SHA512:
6
- metadata.gz: 0339360367affaea08aa104c30111fddbce757581b90a12fca1a6864c44e9181d1dd7cd1750ea1faf1adafbddc5e15513d28a302600fd4fc609f7b94244d6070
7
- data.tar.gz: d6af35bfaba87880eff13126372b0d27ac83de9f3511da109327e0567a81268604ee8e6702e9efb1c7a99beabc67e4114067400d6534fed305706f1d7fcb019e
6
+ metadata.gz: 9f28cd34e259c5c6537016a32cc8c11190898328584c6d48548651b659986a57db9231b1e95d739750b1d493b5c1930ed0237484bcfcab07253ef58e82e014f9
7
+ data.tar.gz: edb622626765bd919c198f4ae289e79346b5001f6cc2de03458588de1fbbba7f6ecc67e4f1d9e5802604fcdc9caa15dc5b2e0c474088772cc4a0c007fcb7261d
data/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## v1.1.3
2
+
3
+ Update
4
+
5
+ - Support simple string replace to deploy erb operation
6
+
1
7
  ## v1.1.2
2
8
 
3
9
  Update
@@ -107,9 +107,17 @@ module Rundock
107
107
  def extract_map(backend, binding)
108
108
  map = {}
109
109
  binding.each do |k, v|
110
- map[k] = backend.specinfra_run_command(v[:value]).stdout.strip if v.key?(:value)
110
+ next unless v.key?(:value)
111
111
 
112
112
  # write types other than the command here
113
+ map[k] = case v[:type].to_s
114
+ when 'command'
115
+ backend.specinfra_run_command(v[:value]).stdout.strip
116
+ when 'string'
117
+ v[:value]
118
+ else
119
+ v[:value]
120
+ end
113
121
  end
114
122
 
115
123
  map
@@ -1,3 +1,3 @@
1
1
  module Rundock
2
- VERSION = '1.1.2'
2
+ VERSION = '1.1.3'
3
3
  end
@@ -10,8 +10,8 @@
10
10
  erb: true
11
11
  binding:
12
12
  erb_val_1:
13
- type: command
14
- value: 'echo "runrunrundock"'
15
- erb_val_2:
16
13
  type: command
17
14
  value: 'uname'
15
+ erb_val_2:
16
+ type: string
17
+ value: 'dondondonruck'
@@ -2,6 +2,6 @@ require 'spec_helper'
2
2
 
3
3
  describe file('/var/tmp/hello_rundock_from_deploy_erb_dst_file_scenario') do
4
4
  it { should be_file }
5
- its(:content) { should match(/Hello Rundock from deploy erb runrunrundock Scenario./) }
6
- its(:content) { should match(/Linux/) }
5
+ its(:content) { should match(/Hello Rundock from deploy erb Linux Scenario./) }
6
+ its(:content) { should match(/dondondonruck/) }
7
7
  end
@@ -24,6 +24,6 @@ deploy_task:
24
24
  binding:
25
25
  erb_val_1:
26
26
  type: command
27
- value: "echo 'runrunrundock'"
27
+ value: "uname"
28
28
  erb_val_2:
29
- value: 'uname'
29
+ value: 'dondondonruck'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rundock
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - hiracy
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-01-11 00:00:00.000000000 Z
11
+ date: 2018-01-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler