Skip to content

Commit

Permalink
Merge pull request puppetlabs#101 from dylanratcliffe/issue_100
Browse files Browse the repository at this point in the history
(puppetlabs#100) Changed hiera.yaml hierarchy
  • Loading branch information
dylanratcliffe committed Jul 13, 2017
2 parents 9b99895 + 8f3f337 commit dcfcb31
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions README.md
Expand Up @@ -285,7 +285,7 @@ If you have hiera data inside your controlrepo (or somewhere else) the Controlre

**WARNING:** This assumes that the path to your hiera data (datadir) is relative to the root of the controlrepo, if not it will fall over.

**Alternatively:**, if you are using cool new per-environment hiera config made available in puppet 4.x, the tool will automatically detect this and everything should work.
**Alternatively:**, if you are using cool new per-environment hiera config made available in puppet 4.x (Now called Hiera 5), the tool will automatically detect this and everything should work. If you want to use a different v5 `hiera.yaml` for testing, pleace it under the spec directory. Note that the datadir must be relative to the location of the hiera.yaml file in this instance. i.e. `../data`

## Spec testing

Expand Down Expand Up @@ -616,4 +616,3 @@ Cheers to all of those who helped out:
- jairojunior
- natemccurdy
- aardvark

2 changes: 1 addition & 1 deletion lib/onceover/controlrepo.rb
Expand Up @@ -335,8 +335,8 @@ def fixtures

def hiera_config_file
# try to find the hiera.iyaml file
hiera_config_file = File.expand_path('./hiera.yaml',@spec_dir) if File.exist?(File.expand_path('./hiera.yaml',@spec_dir))
hiera_config_file = File.expand_path('./hiera.yaml',@root) if File.exist?(File.expand_path('./hiera.yaml',@root))
hiera_config_file = File.expand_path('./hiera.yaml',@spec_dir) if File.exist?(File.expand_path('./hiera.yaml',@spec_dir))
hiera_config_file
end

Expand Down

0 comments on commit dcfcb31

Please sign in to comment.