Skip to content

tests: enable telnet again and instead remove netcat apparmor profile#16683

Open
alfonsosanchezbeato wants to merge 2 commits intocanonical:masterfrom
alfonsosanchezbeato:enable-telnet-again
Open

tests: enable telnet again and instead remove netcat apparmor profile#16683
alfonsosanchezbeato wants to merge 2 commits intocanonical:masterfrom
alfonsosanchezbeato:enable-telnet-again

Conversation

@alfonsosanchezbeato
Copy link
Member

The netcat apparmor profile was preventing access to ports exposed by qemu. Remove it from the kernel and revert the previous change that used pipes to workaround the issue, as we want to be able to use telnet to access the serial port of the device.

@alfonsosanchezbeato alfonsosanchezbeato added Run nested The PR also runs tests inluded in nested suite Auto rerun spread Auto reruns spread up to 4 times in non-draft PRs w/ >=1 approval and <20 fails in any fund. system labels Feb 26, 2026
@github-actions
Copy link

github-actions bot commented Feb 26, 2026

Fri Feb 27 21:55:58 UTC 2026
The following results are from: https://github.com/canonical/snapd/actions/runs/22497858504

Failures:

Preparing:

  • openstack:amazon-linux-2-64:tests/main/refresh-all
  • openstack:debian-sid-64:tests/unit/
  • openstack:debian-sid-64:tests/main/
  • openstack:debian-sid-64:tests/regression/
  • openstack:debian-sid-64:tests/main/
  • openstack:debian-sid-64:tests/completion/
  • openstack:debian-sid-64:tests/main/
  • openstack:debian-sid-64:tests/smoke/
  • openstack:debian-sid-64:tests/unit/
  • openstack:debian-sid-64:tests/unit/
  • openstack:debian-sid-64:tests/smoke/
  • openstack:debian-sid-64:tests/main/
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/hybrid-fde-all-key-databases:dbx
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-fault-inject
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/remount-hotplug
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-factory-reset:fde
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-set-efi-boot-variables
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-gadget-reseal
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/bad-try-kernel-no-reboot
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-basic
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-fault-inject-on-install:snapd_reboot_auto_connect
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-kernel-failover:bad_text
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-kernel-failover:bad_initrd
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/coreconfig-services
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/core20-factory-reset:nofde
  • openstack-ext:ubuntu-26.04-64:tests/nested/core/kernel-revert-after-boot
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/fde-auth-support-on-hybrid
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/hybrid-fde-all-key-databases:pk
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/uc-update-assets-secure:boot
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-nofde-dbx
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-boot-config-update:gadgetextra
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-fault-inject-on-update-config:gadget_panic_command_line
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core-broken-fde-state
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/uc-update-assets-secure:seed
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/uc20-storage-safety:preferunencrypted
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/recovery-system:no_test_or_default
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-4k-sector-size:logical
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/remodel-with-components-offline
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-boot-config-update:nogadget
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-set-efi-boot-vars:BOOTDIR_NOSEC
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/cmdline-remove-append
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/hybrid-fde-recovery-keys
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/broken-model:tpm
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/hybrid-xkb-kcmdline
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/broken-model:hook
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-set-efi-boot-vars:UBUNTUDIR_NOSEC
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/install-in-initrd-no-preseed:plain
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/uc-update-command-line-secure
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-set-efi-boot-vars:BOOTDIR
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/uc-grub-boot-chains
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/hybrid-fde-all-key-databases:kek
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/recovery-system:tested_and_default
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-set-efi-boot-vars:UBUNTUDIR
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/hybrid-fde-all-key-databases:db
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/hybrid-tpm-fde-preinstall-check
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/devmode-snap-seeded-dangerous
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/uc20-fde-hooks:tokens
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-da-lockout:encrypted
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/uc20-fde-hooks:files
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-fde-dbx
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-boot-config-update:gadgetfull
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/uc-update-assets-secure:both
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/install-in-initrd-no-preseed:encrypted
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/recovery-system:default
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-4k-sector-size:physical_only
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/remodel-with-components
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack-arm:ubuntu-core-24-arm-64:tests/main/graphical-user-daemons
  • openstack:ubuntu-18.04-64:tests/regression/lp-1815869

Executing:

  • openstack:amazon-linux-2-64:tests/main/interfaces-content-compatibility
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/minimal-smoke:secboot_disabled
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/muinstaller-real:encrypted
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/muinstaller-real:partial
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/muinstaller-real:preseed
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/install-min-size
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/muinstaller-real:plain
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/install-volume-assignment
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/core20-install-mode-shutdown-via-hook
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/muinstaller-real:seeded
  • openstack-ext:ubuntu-26.04-64:tests/nested/manual/minimal-smoke:secboot_enabled
  • openstack-arm:ubuntu-24.04-arm-64:tests/unit/go:clang
  • openstack-arm:ubuntu-24.04-arm-64:tests/unit/go:gcc
  • openstack-arm:ubuntu-core-24-arm-64:tests/main/dbus-activation-system
  • garden:ubuntu-core-18-64:tests/core/gadget-kernel-refs-update-pc
  • openstack:ubuntu-26.04-64:tests/unit/go:gcc
  • openstack:ubuntu-26.04-64:tests/main/snapd-state
  • openstack:ubuntu-26.04-64:tests/main/server-snap:pythonServer
  • openstack:ubuntu-26.04-64:tests/main/server-snap:goServer
  • openstack:ubuntu-26.04-64:tests/main/desktop-portal-filechooser
  • openstack:ubuntu-26.04-64:tests/main/desktop-portal-open-uri
  • openstack:ubuntu-26.04-64:tests/main/interfaces-firewall-control
  • openstack:ubuntu-26.04-64:tests/main/interfaces-network
  • openstack:ubuntu-26.04-64:tests/main/upgrade-from-release
  • openstack:ubuntu-26.04-64:tests/main/desktop-portal-open-file
  • openstack:ubuntu-26.04-64:tests/main/xdg-open-portal
  • openstack:ubuntu-26.04-64:tests/main/interfaces-network-bind
  • openstack:ubuntu-26.04-64:tests/main/try
  • openstack:ubuntu-16.04-64:tests/unit/go:static

Restoring:

  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-selinux-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-64:
  • openstack:opensuse-tumbleweed-64:

Skipped tests from snapd-testing-skip

  • openstack-arm:ubuntu-24.04-arm-64:tests/main/i18n
  • openstack-arm:ubuntu-core-24-arm-64:tests/main/i18n
  • openstack:debian-sid-64:tests/main/interfaces-network-status-classic
  • openstack:ubuntu-24.04-64:tests/main/i18n
  • openstack:ubuntu-26.04-64:tests/main/i18n

@codecov
Copy link

codecov bot commented Feb 27, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 77.59%. Comparing base (0f390a0) to head (a5d6714).

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #16683      +/-   ##
==========================================
+ Coverage   77.54%   77.59%   +0.05%     
==========================================
  Files        1360     1349      -11     
  Lines      187256   187161      -95     
  Branches     2446     2446              
==========================================
+ Hits       145200   145230      +30     
+ Misses      33278    33158     -120     
+ Partials     8778     8773       -5     
Flag Coverage Δ
unittests 77.59% <ø> (+0.05%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.


# On UC 26.04, the netcat apparmor profile is not allowing access to the
# ports exposed by qemu, remove it.
apparmor_parser -R /etc/apparmor.d/nc.openbsd || true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why it has || true?

could we have instead a check like?

if os.query is-ubuntu-ge 26.04; then 
    apparmor_parser -R /etc/apparmor.d/nc.openbsd
fi

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed

We will instead remove the netcat apparmor profile.

This reverts commit 40770c7.
as it prevents access to ports exposed by qemu.
@alfonsosanchezbeato
Copy link
Member Author

I've rebased to take also the unsquashfs patch, fingers crossed to get full nested UC26 tests green now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Auto rerun spread Auto reruns spread up to 4 times in non-draft PRs w/ >=1 approval and <20 fails in any fund. system Run nested The PR also runs tests inluded in nested suite

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants