rake-terraform-wrapper 0.3.0 → 0.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/ruby/terraform/configuration.rb +12 -4
- data/lib/ruby/terraform/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 47dd7d0777605fd276c6f3756d32e12dd2287a02e82ddbde225be8b681ab85ed
|
4
|
+
data.tar.gz: 8c148cbb511dab03353b8e53ded260df1648ea2001067b0a7806e497a5ccf326
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 213c80d5eecca76180c3b657d62da22cb2e6b461dc2fc8d81ed30437df4c2bdf488ff351167d5efbba108549b189a29ce08a9ec11c6809ca9dc8fbeae5110290
|
7
|
+
data.tar.gz: cdabc17af7030ba7ecfd95978b7adb50562d3671c7c72d3804d94ca567cb482a27a18ab180c06f3da89c14b9aebdfbe635aafc668bee3f6e5f3ba389c2d9871e
|
data/Gemfile.lock
CHANGED
@@ -6,18 +6,26 @@ module Ruby
|
|
6
6
|
attr_accessor :binary
|
7
7
|
|
8
8
|
def initialize(opts = {})
|
9
|
-
@terraform_version = opts[:terraform_version]
|
10
|
-
@download_path = opts[:download_path]
|
9
|
+
@terraform_version = opts[:terraform_version]
|
10
|
+
@download_path = opts[:download_path]
|
11
11
|
@binary = opts[:terraform_binary]
|
12
12
|
end
|
13
13
|
|
14
|
+
def terraform_version
|
15
|
+
@terraform_version ||= Ruby::Terraform::TERRAFORM_VERSION
|
16
|
+
end
|
17
|
+
|
18
|
+
def download_path
|
19
|
+
@download_path ||= File.expand_path("~/.terraform-bin/#{terraform_version}")
|
20
|
+
end
|
21
|
+
|
14
22
|
def binary
|
15
23
|
if @binary
|
16
24
|
@binary
|
17
25
|
elsif OS.windows?
|
18
|
-
"#{@download_path}/terraform.exe"
|
26
|
+
@binary ||= "#{@download_path}/terraform.exe"
|
19
27
|
else
|
20
|
-
"#{@download_path}/terraform"
|
28
|
+
@binary ||= "#{@download_path}/terraform"
|
21
29
|
end
|
22
30
|
end
|
23
31
|
end
|