diff --git a/CHANGELOG.md b/CHANGELOG.md index 6f02148..d7f63b1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,6 @@ ### 1.24.1 / 2021-10-27 * Fixed: + * Worked around a bug in 'puppet lookup' - PUP-11402 * Updated calls to the operating system fact when connecting to RHSM ### 1.24.0 / 2021-10-05 diff --git a/lib/simp/beaker_helpers.rb b/lib/simp/beaker_helpers.rb index 2ea88ba..45686a7 100644 --- a/lib/simp/beaker_helpers.rb +++ b/lib/simp/beaker_helpers.rb @@ -1244,8 +1244,11 @@ def copy_hiera_data_to(sut, path) # # @returns [String] Path to the Hieradata directory on the target system def hiera_datadir(sut) + # A workaround for PUP-11042 + sut_environment = sut.puppet_configprint['environment'] + # This output lets us know where Hiera is configured to look on the system - puppet_lookup_info = on(sut, 'puppet lookup --explain test__simp__test', :silent => true).output.strip.lines + puppet_lookup_info = on(sut, "puppet lookup --explain --environment #{sut_environment} test__simp__test", :silent => true).output.strip.lines if sut.puppet_configprint['manifest'].nil? || sut.puppet_configprint['manifest'].empty? fail("No output returned from `puppet config print manifest` on #{sut}")