Skip to content

Commit

Permalink
Fetch region from configuration in test task.
Browse files Browse the repository at this point in the history
  • Loading branch information
tobyclemson committed Jun 10, 2021
1 parent 9160716 commit 1cf8ab9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Rakefile
Expand Up @@ -134,7 +134,7 @@ namespace :test do
mkdir_p(plugin_cache_directory)

ENV['TF_PLUGIN_CACHE_DIR'] = plugin_cache_directory
ENV['AWS_REGION'] = 'eu-west-2'
ENV['AWS_REGION'] = configuration.region
end
end

Expand Down
6 changes: 6 additions & 0 deletions lib/configuration.rb
Expand Up @@ -29,6 +29,12 @@ def work_directory
@delegate.work_directory
end

def region
@delegate
.for_scope(project_directory: project_directory)
.region
end

def public_address
PublicAddress.as_ip_address
end
Expand Down

0 comments on commit 1cf8ab9

Please sign in to comment.