111 Commits

Author SHA1 Message Date
Christian Breunig
d5db3bf117 T861: use custom Kernel certificate over the root shim signing certificate 2025-03-18 16:24:43 +01:00
Christian Breunig
4d66688c2e
T7140: increase CI test timeout 3h -> 5h 2025-02-22 07:36:54 +01:00
ckath
7416cd4ce9 T7140: check-qemu-install: fix unparsable command 2025-02-06 21:28:58 +01:00
Viacheslav Hletenko
d52077a6fc T7125: add show version vyos-1x for smoketest 2025-02-02 10:03:58 +00:00
Viacheslav Hletenko
5f4e2acd16 T7106: Extend check-qemu-install to show vpp version 2025-01-30 11:27:43 +00:00
Christian Breunig
f5887de05e Testsuite: T7043: make build/manifest.json optional
Support loading and testing random ISO images without the need for
build/manifest.json. If the file is detected - tests are run. If file is
not found - those tests are skipped.
2025-01-22 20:44:56 +01:00
Viacheslav Hletenko
51895a5c98 T7043: Add arguments for CPU and memory for the check-qemu-install
Some smoketest requires more than 4G memory.
And --cpu and --memory args for check-qemu-install
2025-01-11 11:51:10 +00:00
Christian Breunig
f8b88e54bc T7019: use VyOS release train in /etc/os-release codename over Debian release
VyOS is based on Debian
* VyOS 1.3 -> Debian Buster (VyOS equuleus)
* VyOS 1.4 -> Debian Bookworm (VyOS sagitta)
* VyOS 1.5 -> Debian Bookworm (and then trixie) (VyOS circinus)
* VyOS rolling -> Debian Bookworm (and then trixie) (VyOS t.b.d.)

When running
  vyos@vyos:~$ lsb_release -a
  Distributor ID: VyOS
  Description:    VyOS 1.5-rolling-202501031241 (current)
  Release:        1.5-rolling-202501031241
  Codename:       bookworm

The codename in use is the Debian base distribution. This should be changed to
the VyOS release name.
2025-01-05 20:00:49 +01:00
Christian Breunig
dabd5b2a6a Testsuite: T6999: validate content of /etc/os-release in target system
The file /etc/os-release is written during image build, but it's content is not
validated that it can be used by e.g. "lsb_release -a" command.
2025-01-03 17:00:52 +01:00
Christian Breunig
bf01c00d04 Testsuite: T861: use proper base MAC address from RFC7042
Commit 085df7615a ("Testsuite: T861: always use 2 VCPUs") also altered the base
MAC address used by QEMU to a locally administered one. Something that looked
"right" in the beginning turned out to break the smoketest platform.

The reason is the locally administered bit is evaluated in [1] and if set and
not on the exclusion list (as it was a Realtek base MAC address before), the
interface in question is not considered persistent and thus not added to the
configuration file upon system startup.

1: 825743b6bc/src/helpers/vyos-interface-rescan.py (L73-L74)
2025-01-01 20:10:52 +01:00
Christian Breunig
81ae7efbac Testsuite: T6991: inform smoketest about this environment 2024-12-31 14:20:49 +01:00
Christian Breunig
20b20efcca Testsuite: T861: boot system in serial console mode to get the full boot log 2024-12-31 14:20:32 +01:00
Christian Breunig
085df7615a Testsuite: T861: always use 2 VCPUs 2024-12-31 14:13:04 +01:00
Nataliia Solomko
a975e075fd T3501: Fix cli command in check-qemu-install 2024-11-12 09:48:28 +02:00
Christian Breunig
57d5afe0ff Testsuite: T6494: add new make target "test-interfaces"
We can not run the interface related tests, and non interface related
testcases in parallel to speedup the entire build process.
2024-10-06 16:16:02 +02:00
Christian Breunig
d235b31a09 T861: sign all Kernel modules with an ephemeral key
The shim review board (which is the secure boot base loader) recommends using
ephemeral keys when signing the Linux Kernel. This commit enables the Kernel
build system to generate a one-time ephemeral key that is used to:

* sign all build-in Kernel modules
* sign all other out-of-tree Kernel modules

The key lives in /tmp and is destroyed after the build container exits and is
named: "VyOS build time autogenerated kernel key".

In addition the Kernel now uses CONFIG_MODULE_SIG_FORCE. This now makes it
unable to load any Kernel Module to the image that is NOT signed by the
ephemeral key.
2024-09-25 20:24:21 +02:00
sarthurdev
d60f5222c2 tpm: T4919: Fix TPM test for changes in 7f23b57 2024-09-17 11:30:36 +02:00
sarthurdev
e35345a446 tpm: T4919: Fix check for /dev/tpm0 2024-09-17 10:25:36 +02:00
Christian Breunig
fd737172f1 T861: add UEFI Secure Boot support
This adds support for UEFI Secure Boot. It adds the missing pieces to the Linux
Kernel and enforces module signing. This results in an additional security
layer where untrusted (unsigned) Kernel modules can no longer be loaded into
the live system.

NOTE: This commit will not work unless signing keys are present. Arbitrary
keys can be generated using instructions found in:

  data/live-build-config/includes.chroot/var/lib/shim-signed/mok/README.md
2024-09-14 23:05:23 +02:00
Christian Breunig
e86bfd7ab9 Testsuite: T861: add explicit --smoketest argument
In the past the CLI based smoketest was always executed under an else branch in
the testcase if-statement. Instead of using negative logic move all testcases
to positive logic adding an empty "catch all" else path.
2024-09-07 21:32:34 +02:00
Christian Breunig
6ef7069098 Testsuite: T861: use fix bootindex for install medium and non-volatile disks
This is required to support proper disk ejection and not reloading the disk on
system reboot when operation in BIOS mode.
2024-09-07 21:32:34 +02:00
Christian Breunig
115fb522c8 Testsuite: T861: add support to use VNC for a graphics console
To use VNC you could run "make test -- --vnc"
2024-09-07 21:32:34 +02:00
Christian Breunig
986b71af2d Testsuite: T861: use variable to define one single place for VM name 2024-09-07 21:32:34 +02:00
Christian Breunig
aa6ca5c65b Testsuite: T861: cleanup imports and use "kernel_flavor" from vyos_defaults 2024-09-07 21:32:34 +02:00
Christian Breunig
e5627bf050 Testsuite: T861: remove option to disable KVM and use soft-emulation
This code path was unused during CI runs.
2024-09-07 21:32:34 +02:00
Christian Breunig
7f23b57b19 Testsuite: T861: eject installation media CD-ROM over powercycle
When moving to UEFI and secure-boot it's better to just reboot the system
for Machine Owner Key installation, then powercycling the machine.

This commit will use `reboot now` over `poweroff` after base system installation
and boot into installed image for smoketest handling.
2024-09-07 21:32:34 +02:00
Christian Breunig
fd7d1d0d20 Kernel: T861: remove superfluous architecture from Kernel string 2024-09-07 21:31:46 +02:00
Matthew Kobayashi
893a90fa60
T6484: Smoketest: Increase KVM memory limit 2024-06-14 10:41:15 +10:00
John Estabrook
6fe57a7042 image-tools: T6154: installer prompts to confirm non-default password 2024-04-16 14:15:51 -05:00
John Estabrook
4a8bc369ef image-tools: T6207: update test script for prompt for boot config 2024-04-07 22:41:42 -05:00
Daniil Baturin
bbddf9d0a3 docker, build: T6119: use python3-tomli instead of python3-toml
for a compliant implementation ot TOML
2024-03-12 20:59:46 +00:00
sarthurdev
d8313d2c2c build: T4919: Fix error due to variable not found 2024-03-08 01:48:05 +01:00
sarthurdev
63a8f9d3c6 config: T4919: Add emulated TPM encryption test 2024-02-20 10:46:01 +01:00
Christian Breunig
b3d0ebaf1d Makefile: add new target qemu-live
Simply boot a live qemu version from the latest ISO build

(10:18) cpo lnx01:~/vyos-build [current] # sudo make qemu-live
if [ ! -f build/live-image-amd64.hybrid.iso ]; then
echo "Could not find build/live-image-amd64.hybrid.iso"
exit 1
fi
scripts/check-qemu-install --qemu-cmd build/live-image-amd64.hybrid.iso
 INFO - Creating Disk image testinstall-20231119-101823-4483.img
SeaBIOS (version 1.16.2-debian-1.16.2-1)
Machine UUID f48b60b2-e6ad-49ef-9d09-4245d0585e52
Booting from DVD/CD...

ISOLINUX 6.04 20200816 ETCD Copyright (C) 1994-2015 H. Peter Anvin et al
2023-11-19 10:18:49 +01:00
John Estabrook
64796852a4 image: T4516: update test script for changes in prompts/partition id 2023-11-15 15:33:42 -06:00
John Estabrook
ecd3727d63 smoketest: T5607: adjust for non-deterministic scsi device probing 2023-09-20 15:22:32 -05:00
sarthurdev
4727dc1756 smoketest: Allow selection of smoketests to run
Example:
`make test MATCH="interfaces|policy"` will only run interfaces and policy tests
2023-09-14 20:04:54 +02:00
Apachez
fa1462aa6d T5562: Fix -smp syntax for qemu-system-x86_64 2023-09-09 12:24:55 +02:00
Christian Breunig
a863fe0b03 Testsuite: fix qemu SMP configuration 2023-09-09 07:33:44 +02:00
Viacheslav Hletenko
84fba9f897 T5024: Try to shutdown several times for qemu install script
The first shutdown for qemu doesn't work
Try to shutdown several times
2023-02-22 09:03:28 +00:00
sarthurdev
52073f8ee6 debian: T5003: Increase VM memory - tests failed due to OOM condition 2023-02-13 11:20:49 +01:00
Christian Poessinger
be1d5e0165 Testsuite: T3664: move to new toml based input files 2022-10-07 22:02:58 +02:00
sarthurdev
53d229d200 smoketest: Move PKI file generate to script in vyos-1x 2022-06-30 15:45:23 +02:00
sarthurdev
5a8785f091 openvpn: T4485: Add intermediate CA for smoketest 2022-06-29 17:33:00 +02:00
Christian Poessinger
d9b81c85dc Testsuite: add new '--qemu-cmd' switch to print the commandline to launch QEMU manually 2022-04-18 09:19:07 +02:00
Christian Poessinger
e67312b02d Testsuite: enable DHCP on eth0 - future smoketests could now verify DHCP 2022-04-18 09:10:01 +02:00
Christian Poessinger
e326536380 Testsuite: increase memory to 2G for fastnetmon testcase 2022-04-11 21:00:31 +02:00
Christian Poessinger
4ccdaf58fc Testsuite: fix cdrom boot in UEFI mode 2021-12-26 18:33:51 +01:00
Christian Poessinger
3a8d74b333 Revert "Testsuite: limit QEmu test disk size to 1G to not waste space on build host"
This reverts commit a5e591fa9b66b229f7296de177a570c7b7126be4.
2021-12-26 17:57:01 +01:00
Christian Poessinger
1960c1c259 Testsuite: limit QEmu test disk size to 1G to not waste space on build host 2021-12-26 09:04:04 +01:00