The change of plans sounds good to me. I remember discussing that for
Jammy the follow-up patch wouldn't need to precede the in-flight ones as
per Mitch's comment #19 since the default on Jammy is .lists rather than
.sources. Therefore we would not consider it a regression that
.sources.save don't revert and that patch could come later.

Jammy Verification
==================
root@landscape-client:~# apt info landscape-client

Package: landscape-client
Version: 23.02-0ubuntu1~22.04.6
Priority: optional
Section: admin
Origin: Ubuntu
Maintainer: Ubuntu Developers <[email protected]>
Original-Maintainer: Landscape Team <[email protected]>
Bugs: https://bugs.launchpad.net/ubuntu/+filebug
Installed-Size: 606 kB
Depends: python3:any, debconf (>= 0.5) | debconf-2.0, libc6 (>= 2.34), 
landscape-common (= 23.02-0ubuntu1~22.04.6), python3-pycurl
Homepage: https://github.com/CanonicalLtd/landscape-client
Download-Size: 113 kB
APT-Manual-Installed: yes
APT-Sources: http://archive.ubuntu.com/ubuntu jammy-proposed/main amd64 Packages
Description: Landscape administration system client
 Landscape is a web-based tool for managing Ubuntu systems. This
 package is necessary if you want your machine to be managed in a
 Landscape account.
 .
 This package provides the Landscape client and requires a Landscape account.

Environment Sanity Check Before Applying any Profiles:
------------------------------------------------------

# Check contents of /etc/apt/
root@landscape-client:~# ls /etc/apt/
apt.conf.d  auth.conf.d  keyrings  preferences.d  sources.list  sources.list.d  
trusted.gpg.d

We see sources.list and sources.list.d, and sources.list correctly has
the default Ubuntu sources:

root@landscape-client:~# cat /etc/apt/sources.list
## Note, this file is written by cloud-init on first boot of an instance
...
Continued
...

deb http://archive.ubuntu.com/ubuntu jammy-updates main restricted
...
deb http://archive.ubuntu.com/ubuntu jammy multiverse
... so on

# Check contents of /etc/apt/sources.list.d
root@landscape-client:~# ls /etc/apt/sources.list.d/
ubuntu-esm-apps.list  ubuntu-esm-infra.list

# Add -proposed in /etc/apt/sources.list.d/ubuntu.sources
root@landscape-client:~# cat <<EOF >> /etc/apt/sources.list.d/ubuntu.sources
Types: deb
URIs: http://archive.ubuntu.com/ubuntu
Suites: jammy-proposed
Components: main universe restricted multiverse
Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg
EOF

Test Application of Repository Profile
--------------------------------------
# Create a repository profile called "test-profile" in the dashboard and select 
"Associate to all instances" then wait a few minutes for the profile to be 
distributed to the client. Eventually the profile appears and the existing 
*.sources and *.list files move to *.sources.save and *.list.save

root@landscape-client:~# ls /etc/apt/sources.list.d/
landscape-test-profile.list  ubuntu-esm-apps.list.save  
ubuntu-esm-infra.list.save  ubuntu.sources.save

Similarly, /etc/apt/sources.list is moved to sources.list.save and
sources.list is replaced to indicate that this machine's repositories
are Landscape-managed

root@landscape-client:~# ls /etc/apt/
apt.conf.d  auth.conf.d  keyrings  preferences.d  sources.list  sources.list.d  
sources.list.save  trusted.gpg.d

root@landscape-client:~# cat /etc/apt/sources.list
# Landscape manages repositories for this computer
# Original content of sources.list can be found in sources.list.save

Test Removal of Repository Profile
----------------------------------
# Remove the profile in the dashboard. Shortly after the client is updated and 
the /etc/apt/sources.list.save moves back, and 
/etc/apt/sources.list.d/landscape-test-profile.list moves to 
landscape-profile-test.list.save

root@landscape-client:~# ls /etc/apt/
apt.conf.d  auth.conf.d  keyrings  preferences.d  sources.list  sources.list.d  
trusted.gpg.d

root@landscape-client:~# ls /etc/apt/sources.list.d/
landscape-test-profile.list.save  ubuntu-esm-apps.list.save  
ubuntu-esm-infra.list.save  ubuntu.sources.save

This is the expected behaviour as Jammy does not yet have the follow-up
patch which restores the *.sources.save files

** Tags removed: verification-needed verification-needed-jammy
** Tags added: verification-done verification-done-jammy

-- 
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