** Description changed:

  [Impact]
  
    * Currently, as reported above, Landscape repository profiles only act
  upon .list files while .sources remain in effect. As Noble transitioned
  from the default source definition being the traditional .list files to
  DEB822 .sources files, this bug manifested when a customer noticed
  sources that they wanted disabled were still appearing in apt update.
  
    * The determined solution was to add pattern matching for .sources
  extensions as well as .list files. Merged PR here:
  https://github.com/canonical/landscape-client/pull/298
  
    * The first LTS to support DEB822 .sources was Xenial, however, the
  first LTS where this format became the default was noble. The proposed
  SRU is to bring this change back to Focal
  
  [Testing]
  
    * To reproduce the problem, apply a repository profile on an affected
  ubuntu system and observe that it does not migrate .sources files to
  .sources.save by listing /etc/apt/sources.list.d/, and running apt
  update to see that the sources are still being used
  
    * Upgrade to the landscape-client packages from proposed and apply a
  Landscape profile, noting that .sources files successfully move to
  .sources.save and no longer appear in the output of apt update
  
-   * Ensure that .list files are also renamed to .list.save (as this is
+   * Ensure that .list files are also renamed to .list.save (as this is
  the current behaviour)
  
  [What can go wrong]
  
    * The change is rather localized and brief, so it is not expected to
  introduce any regressions or problems. Applying a profile may take more
  time due to extra pattern matching and checking - particularly is the
  filesystem has many .sources files
+ 
+   * When removing the profile, both .sources files and .list files
+ should revert back to their state prior to the profile's application. In
+ other words, the sources and list files that were provided by the
+ profile should be removed and the files that were moved to .save should
+ be restored (.save suffix removed). In the first iteration of this SRU
+ it came to our attention that .sources files were not restored. The
+ inclusion of the fix-apt-source-file-management patch should resolve
+ this but there is the possibility that the issue recurs
+ 
+ ----------------------------------
  
  [Original Description]
  
  Somewhat related to LP:2062561, landscape-client currently only appends
  .save to source lists ending in .list, which leaves 822 style lists
  using the .sources extension intact.
  
  This means that applying a repository profile to any machine using the
  new .sources files will still have their public repository sources
  enabled after a repository profile is applied.
  
  https://github.com/canonical/landscape-
  client/blob/main/landscape/client/manager/aptsources.py#L144
  
  This was reported 2024-11-08 internally, and now also reported by a
  customer in case:00400550

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2087852

Title:
  [FFe][SRU] Repository profiles only act on .list files and do not
  affect .source files

To manage notifications about this bug go to:
https://bugs.launchpad.net/landscape-client/+bug/2087852/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to