rake-terraform 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/.gitignore +2 -1
- data/README.md +1 -0
- data/lib/rake-terraform/default_tasks.rb +5 -1
- data/lib/rake-terraform/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MWFiNjc0NjliYzBiNGEyNTUzZWUzMTIyOGIwNTM3NjUyMjkxNjAwZg==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
MGU4ZTNlZDk2ODdmZWMyMGNjZjljZmY0NjUzN2YxZGNlYWMyYTkyYw==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
Y2Q5NTdlZjk4YjNhN2NhOTE0ZTliNmU5M2VjYTUwZDRjZWI4MTcxOTUwM2Q3
|
10
|
+
MjZjODg3ZTFlMmM3OTQyODU2Y2RlNjkyN2VmNzExOGU5YjgwNWI5ZWQzNTQ4
|
11
|
+
NzM0MThkMTMwMjM1MDFjODQ1NjEzODg3YTZmMGJmZTg5Y2ZhMmU=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ZGNhYjA1Zjk1MWRjYWFlNWJhODAxMTBhMjAwYmY2MjZjNTUwNzI3ZjM5YThj
|
14
|
+
N2RiNGE3MWQ1MjgwYmU3YzNlOTNiNzMxMjQ2YTEwZTBjNDNhNGU3NTE5NGIz
|
15
|
+
MDcwNDczNjI4ZGNjNmZlZTlmYjEyYjZjNDY5MmQyMzBjNDgyNGY=
|
data/.gitignore
CHANGED
data/README.md
CHANGED
@@ -95,6 +95,7 @@ The following environment variables can be set to tweak `default_task`'s behavio
|
|
95
95
|
* `ENV['TERRAFORM_AWS_PROJECT']` - Sets `t.aws_project` on the `terraform_plan` tasks (default: `default`)
|
96
96
|
* `ENV['TERRAFORM_ENVIRONMENT_GLOB']` - Dir glob used to discover terraform environments (default: `terraform/**/*.tf`)
|
97
97
|
* `ENV['TERRAFORM_OUTPUT_BASE']` - Directory to which plan files are saved/read. The environment name is appended to this automatically (default: `output/terraform`)
|
98
|
+
* `ENV['TERRAFORM_CREDENTIAL_FILE']` - The path to your AWS credentials file (default: `~/.aws/credentials`)
|
98
99
|
|
99
100
|
## Contributing
|
100
101
|
|
@@ -3,6 +3,9 @@ require 'rake_terraform'
|
|
3
3
|
namespace :terraform do
|
4
4
|
env_glob = ENV['TERRAFORM_ENVIRONMENT_GLOB'] || 'terraform/**/*.tf'
|
5
5
|
output_base = ENV['TERRAFORM_OUTPUT_BASE'] || 'output/terraform'
|
6
|
+
credential_file = ENV['TERRAFORM_CREDENTIAL_FILE'] || '~/.aws/credentials'
|
7
|
+
aws_project = ENV['TERRAFORM_AWS_PROJECT'] || 'default'
|
8
|
+
|
6
9
|
environments = (Dir.glob env_glob).map { |f| File.dirname f }.uniq
|
7
10
|
|
8
11
|
environments.each do |env|
|
@@ -12,8 +15,9 @@ namespace :terraform do
|
|
12
15
|
desc "Plan migration of #{short_name}"
|
13
16
|
terraform_plan "plan_#{short_name}" do |t|
|
14
17
|
t.input_dir = env
|
15
|
-
t.aws_project =
|
18
|
+
t.aws_project = aws_project
|
16
19
|
t.output_file = plan_path
|
20
|
+
t.credentials = credential_file
|
17
21
|
end
|
18
22
|
|
19
23
|
desc "Execute plan for #{short_name}"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rake-terraform
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Norm MacLennan
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-03-
|
11
|
+
date: 2015-03-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|