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

apt : apt::source parameters do not match the naming convention in sources.list

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: apt
    • Labels:
      None
    • Template:
    • QA Risk Assessment:
      Needs Assessment

      Description

       

      the `apt::source` resource uses the following parameters to define a sources.list entry:

      • location
      • release
      • repos

      This naming convention is confusing:

      1. a machine might run a given release, but can also have different suites configured. in this case using release is ambiguous and causes confusion such as https://github.com/puppetlabs/puppetlabs-apt/pull/905 - suite should be used here instead
      2. a repo is normally what a sources.list entry points at, it's not /part/ of a repo - components is the proper wording here
      3. location is okay, but is usually called uri in the apt documentation

      The upstream documentation is here:

      https://manpages.debian.org/buster/apt/sources.list.5.en.html

      It specifically gives this example:

      deb [ option1=value1 option2=value2 ] uri suite [component1] [component2] [...]
      deb-src [ option1=value1 option2=value2 ] uri suite [component1] [component2] [...] 

      I would propose that we switch from location, release, repos to:

      • uri
      • suite
      • components

      This would be an API-breaking changes, but could be introduced in a backwards compatible way, with deprecation warnings that would get dropped at a major release.

      (I would also add an options hash to allow arbitrary options to be passed into the sources.list, but that's a different topic, which is covered by the discussion in https://tickets.puppetlabs.com/browse/MODULES-9695 )

       

      Thanks!

        Attachments

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            anarcat Antoine
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:

                Zendesk Support