Uploaded image for project: 'Modules'
  1. Modules
  2. MODULES-3802

create_ini_settings should auto require dependent paths

    Details

    • Type: Bug
    • Status: Open
    • Priority: Normal
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: inifile
    • Labels:
      None
    • Environment:

      CentOS7.2, Puppet 3.8.7 (but that doesn't matter)

    • Template:
    • Acceptance Criteria:
      Hide

      The enclosing directory should automatically be a dependency

      Show
      The enclosing directory should automatically be a dependency

      Description

      The following puppet code:

      # (oversimplified)
        $config_file = '/etc/letsencrypt/cli.ini'
        file { '/etc/letsencrypt': ensure => directory }
      # (assume $_config_joined is populated)
        create_ini_settings($_config_joined, { path => $config_file })
      

      ... will try to create the cli.ini file before /etc/letsencrypt exists.

      [15:36] <TommyTheKid> How can I make sure that the "enclosing directory" exists before the ini file when using create_ini_settings() ? I need it to depend on the package or at least the File of the enclosing directory, but its trying to create the file before it exists
      [15:42] <binford2k> TommyTheKid: well that's kind of a bummer. It doesn't actually autorequire the file... it should
      [15:43] <binford2k> TommyTheKid: can you file a ticket?
      [15:43] <binford2k> TommyTheKid: in the meantime, just require => File ['/path/to/file']

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              TommyTheKid Tommy McNeely
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:

                Zendesk Support