Compare commits

..

3 commits

Author SHA1 Message Date
Brian C. Lane
18b3b3e744 - New lorax documentation - 30.19 (bcl@redhat.com)
- Replace isoinfo with pycdlib (bcl@redhat.com)
- Change customizations.firewall to append items instead of replace (bcl@redhat.com)
- Update customizations.services documentation (bcl@redhat.com)
- lorax-composer: Add services support to blueprints (bcl@redhat.com)
- lorax-composer: Add firewall support to blueprints (bcl@redhat.com)
- lorax-composer: Add locale support to blueprints (bcl@redhat.com)
- lorax-composer: Fix customizations when creating a recipe (bcl@redhat.com)
- Update docs for new timezone section (bcl@redhat.com)
- lorax-composer: Add timezone support to blueprint (bcl@redhat.com)
- Proposal for adding to the blueprint customizations (bcl@redhat.com)
- Add test for starting compose with deleted blueprint (jikortus@redhat.com)
- Update VMware info for VMware testing (chrobert@redhat.com)
- tests: Cleanup on failure of in_tempdir (bcl@redhat.com)
- Change [[modules]] to [[packages]] in tests (atodorov@redhat.com)
- Add new test to verify compose paths exist (atodorov@redhat.com)
- Add new sanity tests for blueprints (atodorov@redhat.com)
- Fixes for locked root account test (jikortus@redhat.com)
- Correct "recipes" use to "blueprints" in composer-cli description (kwalker@redhat.com)
- Fix keeping files on Amazon s3 (jstodola@redhat.com)
- Allow to keep objects in AWS (jstodola@redhat.com)
- Fix the google cloud boot console settings (dshea@redhat.com)
- Add a compose type for alibaba. (dshea@redhat.com)
- Add a new compose type for Hyper-V (dshea@redhat.com)
- Add a compose check for google cloud images. (dshea@redhat.com)
- Add a compose type for Google Compute Engine (dshea@redhat.com)
- Add a new output type, tar-disk. (dshea@redhat.com)
- Support compressing single files. (dshea@redhat.com)
- Add an option to align the image size to a multiplier. (dshea@redhat.com)
- Add documentation references to lorax-composer service files (bcl@redhat.com)
- Add more tests for gitrpm.py (bcl@redhat.com)
- lorax-composer: Fix installing files from [[repos.git]] to / (bcl@redhat.com)
- Make it easier to generate docs for the next release (bcl@redhat.com)
- pylorax.ltmpl: Add a test for missing quotes (bcl@redhat.com)
- Don't remove chmem and lsmem from install.img (bcl@redhat.com)
- Add checks for disabled root account (jikortus@redhat.com)
- Update datastore for VMware testing (chrobert@redhat.com)
- Add tests using repos.git in blueprints (bcl@redhat.com)
- Move git repo creation into tests/lib.py (bcl@redhat.com)
- rpmgit: catch potential errors while running git (bcl@redhat.com)
- tests: Add test for Recipe.freeze() function (bcl@redhat.com)
- Add repos.git support to lorax-composer builds (bcl@redhat.com)
- Add pylorax.api.gitrpm module and tests (bcl@redhat.com)
- Add support for [[repos.git]] section to blueprints (bcl@redhat.com)
- tests: Add python3-mock and python3-sphinx_rtd_theme (bcl@redhat.com)
- Use make ci inside test-in-copy target (atodorov@redhat.com)
- Allow overriding $CLI outside test scripts (atodorov@redhat.com)
- New test: Build live-iso and boot with KVM (atodorov@redhat.com)
- lorax-composer: Return UnknownBlueprint errors when using deleted blueprints (bcl@redhat.com)
- lorax-composer: Delete workspace copy when deleting blueprint (bcl@redhat.com)
- New test: Build qcow2 compose and test it with QEMU-KVM (atodorov@redhat.com)
2019-05-06 16:58:03 -07:00
Brian C. Lane
f3232a9cdc - lorax-composer: pass customization.kernel append to extra_boot_args (bcl@redhat.com)
- Improve logging for template syntax errors (bcl@redhat.com)
- Add extra boot args to the livemedia-creator iso templates (bcl@redhat.com)
- lorax-composer: Add the ability to append to the kernel command-line (bcl@redhat.com)
- Add -iso-level 3 when the install.img is > 4GiB (bcl@redhat.com)
- qemu wasn't restoring the terminal if it was terminated early (bcl@redhat.com)
- Switch the --virt-uefi method to use SecureBoot (bcl@redhat.com)
2019-04-05 15:59:41 -07:00
Brian C. Lane
d0461043fa - tests: Make it easier to update version globs (bcl@redhat.com)
- Update ppc64le isolabel to match x86_64 logic (bcl@redhat.com)
- Add blacklist_exceptions to multipath.conf (bcl@redhat.com)
2019-03-15 12:36:13 -07:00
7 changed files with 731 additions and 964 deletions

View file

@ -1 +0,0 @@
1

115
.gitignore vendored
View file

@ -156,115 +156,6 @@
/lorax-30.14.tar.gz
/lorax-30.15.tar.gz
/lorax-30.16.tar.gz
/lorax-31.0.tar.gz
/lorax-31.1.tar.gz
/lorax-31.2.tar.gz
/lorax-31.3.tar.gz
/lorax-31.4.tar.gz
/lorax-31.5.tar.gz
/lorax-31.6.tar.gz
/lorax-31.7.tar.gz
/lorax-31.8.tar.gz
/lorax-31.9.tar.gz
/lorax-31.10.tar.gz
/lorax-32.0.tar.gz
/lorax-32.1.tar.gz
/lorax-32.2.tar.gz
/lorax-32.3.tar.gz
/lorax-32.4.tar.gz
/lorax-32.5.tar.gz
/lorax-32.6.tar.gz
/lorax-32.7.tar.gz
/lorax-33.0.tar.gz
/lorax-33.1.tar.gz
/lorax-33.2.tar.gz
/lorax-33.3.tar.gz
/lorax-33.4.tar.gz
/lorax-33.5.tar.gz
/lorax-33.6.tar.gz
/lorax-33.7.tar.gz
/lorax-33.8.tar.gz
/lorax-33.9.tar.gz
/lorax-34.0.tar.gz
/lorax-34.1.tar.gz
/lorax-34.2.tar.gz
/lorax-34.3.tar.gz
/lorax-34.4.tar.gz
/lorax-34.5.tar.gz
/lorax-34.6.tar.gz
/lorax-34.7.tar.gz
/lorax-34.8.tar.gz
/lorax-34.9.tar.gz
/lorax-35.0.tar.gz
/lorax-35.1.tar.gz
/lorax-35.2.tar.gz
/lorax-35.3.tar.gz
/lorax-35.4.tar.gz
/lorax-35.5.tar.gz
/lorax-35.6.tar.gz
/lorax-35.7.tar.gz
/lorax-36.0.tar.gz
/lorax-36.1.tar.gz
/lorax-36.2.tar.gz
/lorax-36.3.tar.gz
/lorax-36.4.tar.gz
/lorax-36.5.tar.gz
/lorax-36.6.tar.gz
/lorax-36.7.tar.gz
/lorax-36.8.tar.gz
/lorax-36.9.tar.gz
/lorax-37.0.tar.gz
/lorax-37.1.tar.gz
/lorax-37.2.tar.gz
/lorax-37.3.tar.gz
/lorax-37.4.tar.gz
/lorax-37.5.tar.gz
/lorax-37.6.tar.gz
/lorax-37.7.tar.gz
/lorax-37.8.tar.gz
/lorax-38.0.tar.gz
/lorax-38.1.tar.gz
/lorax-38.2.tar.gz
/lorax-38.3.tar.gz
/lorax-38.4.tar.gz
/lorax-38.5.tar.gz
/lorax-38.6.tar.gz
/lorax-39.0.tar.gz
/lorax-39.1.tar.gz
/lorax-39.2.tar.gz
/lorax-39.3.tar.gz
/lorax-39.4.tar.gz
/lorax-39.5.tar.gz
/lorax-40.0.tar.gz
/lorax-40.1.tar.gz
/lorax-40.2.tar.gz
/lorax-40.3.tar.gz
/lorax-40.4.tar.gz
/lorax-40.5.tar.gz
/lorax-40.6.tar.gz
/lorax-41.0.tar.gz
/lorax-41.1.tar.gz
/lorax-41.2.tar.gz
/lorax-41.3.tar.gz
/lorax-42.0.tar.gz
/lorax-42.1.tar.gz
/lorax-42.2.tar.gz
/lorax-42.3.tar.gz
/lorax-42.4.tar.gz
/lorax-42.5.tar.gz
/lorax-43.0.tar.gz
/lorax-43.1.tar.gz
/lorax-43.2.tar.gz
/lorax-43.3.tar.gz
/lorax-43.4.tar.gz
/lorax-43.5.tar.gz
/lorax-43.6.tar.gz
/lorax-43.7.tar.gz
/lorax-43.8.tar.gz
/lorax-43.9.tar.gz
/lorax-43.10.tar.gz
/lorax-44.0.tar.gz
/lorax-44.1.tar.gz
/lorax-44.2.tar.gz
/lorax-44.3.tar.gz
/lorax-44.4.tar.gz
/lorax-30.17.tar.gz
/lorax-30.18.tar.gz
/lorax-30.19.tar.gz

View file

@ -1,7 +0,0 @@
--- !Policy
product_versions:
- fedora-*
decision_contexts: [bodhi_update_push_stable]
subject_type: koji_build
rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}

1293
lorax.spec

File diff suppressed because it is too large Load diff

View file

@ -1,3 +0,0 @@
summary: Run Lorax tests (build an iso, run mkksiso on it)
execute:
script: ./tests/scripts/run_tests.sh

View file

@ -1 +1 @@
SHA512 (lorax-44.4.tar.gz) = e2be9a13a0aec657bfe9a32dbd51e9024dfcb89471dbc57b8206dccdcd71cf5561fb25f97a7fdaca2b0279a2966b142ddf4e4544577ac2b47171f19648742577
SHA512 (lorax-30.19.tar.gz) = 73553b424b15161a93d250940da94a3d05d9f39e36232be4de675052ca2be2317a92b81a38d75f20b58c51bc078929130887f8c73c68135d7d0766e28180e489

View file

@ -1,274 +0,0 @@
#!/bin/bash
set -eux
FAILANY=0
BOOTISO=/var/tmp/lorax-fedora-iso/images/boot.iso
KSNAME=fedora-minimal.ks
KS="/usr/share/doc/lorax/$KSNAME"
OUTISO=/var/tmp/out.iso
ISODIR=/var/tmp/iso
## Functions for testing mkkiso
function fail {
echo -e "\n\n#### ERROR: $1\n"
FAIL=1
FAILANY=1
}
function status {
if [ "$FAIL" -eq 0 ]; then
echo -e "\n\n#### PASS: $1\n"
else
echo -e "\n\n#### FAIL: $1\n"
fi
}
function running {
FAIL=0
echo -e "\n\n#### RUN: $1\n"
}
# unmount the dirs lazily because sometimes some outside thing is still touching them
function umount_dirs {
umount --lazy "$ISODIR"
rm -f "$OUTISO"
}
[ -e "$ISODIR" ] || mkdir "$ISODIR"
# Only add kickstart
function ks_only {
running "Add kickstart to iso using --ks"
mkksiso --ks $KS $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_ks
status "Add kickstart to iso using --ks"
umount_dirs
}
# Only add kickstart
function ks_pos_only {
running "Add kickstart to iso using positional argument"
mkksiso $KS $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_ks
status "Add kickstart to iso using positional argument"
umount_dirs
}
function test_ks {
## This all needs to be another function
# Is there a kickstart in / of the iso?
[ -e "$ISODIR/$KSNAME" ] || fail "Missing kickstart"
# Is the kickstart in the GRUB2 BIOS config?
grep "inst.ks=.*$KSNAME" "$ISODIR/boot/grub2/grub.cfg" || fail "Missing BIOS grub.cfg kickstart entry"
# Is the kickstart in the UEFI config?
grep "inst.ks=.*$KSNAME" "$ISODIR/EFI/BOOT/grub.cfg" || fail "Missing UEFI grub.cfg kickstart entry"
}
# Add ks and cmdline
function ks_serial {
running "Add kickstart and serial cmdline"
mkksiso -c "console=ttyS0,115200n8" --ks $KS $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_ks
test_serial
status "Add kickstart and serial cmdline"
umount_dirs
}
# Only add serial console to cmdline
function only_serial {
running "Add serial cmdline (no ks)"
mkksiso -c "console=ttyS0,115200n8" $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_serial
status "Add kickstart and serial cmdline"
umount_dirs
}
function test_serial {
# Is the serial in the BIOS config?
grep "console=ttyS0,115200n8" "$ISODIR/boot/grub2/grub.cfg" || fail "Missing BIOS grub.cfg cmdline entry"
# Is the serial in the UEFI config?
grep "console=ttyS0,115200n8" "$ISODIR/EFI/BOOT/grub.cfg" || fail "Missing UEFI grub.cfg cmdline entry"
}
# New VOLID
function new_volid {
running "Use a new VOLID"
mkksiso -V "mkksiso-test" --ks $KS $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_ks
test_volid
status "Use a new VOLID"
umount_dirs
}
function test_volid {
# Is the VOLID in the BIOS config?
grep "hd:LABEL=mkksiso-test" "$ISODIR/boot/grub2/grub.cfg" || fail "Missing BIOS grub.cfg kickstart entry"
# Is the VOLID in the UEFI config?
grep "hd:LABEL=mkksiso-test" "$ISODIR/EFI/BOOT/grub.cfg" || fail "Missing UEFI grub.cfg kickstart entry"
}
# Add extra files
function add_files {
running "Add files"
mkksiso -a /etc/services --ks $KS $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_ks
test_files
status "Add files"
umount_dirs
}
# Remove quiet from the cmdline
function remove_quiet {
running "remove quiet from cmdline (no ks)"
mkksiso --rm "quiet" $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_quiet
status "Remove quiet from cmdline"
umount_dirs
}
function test_quiet {
# Is quiet in the BIOS config?
! grep "append.*quiet" "$ISODIR/boot/grub2/grub.cfg" || fail "quiet not removed from BIOS grub.cfg cmdline entry"
# Is quiet in the UEFI config?
! grep "linux.*quiet" "$ISODIR/EFI/BOOT/grub.cfg" || fail "quiet not removed from UEFI grub.cfg cmdline entry"
}
# Test error if passing both --ks FILE and 3 arguments
function test_two_kickstarts {
running "Test two kickstart error"
mkksiso --ks $KS $KS $BOOTISO $OUTISO && fail "No error using --ks and positional argument"
status "Test two kickstart error"
}
function test_files {
[ -e "$ISODIR/services" ] || fail "Missing file from iso"
}
# Test adding an updates.img file
function add_updatesimg {
running "Add updates.img"
# nothing in the file, just test that it is there
touch /tmp/updates.img
mkksiso -u /tmp/updates.img $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_updatesimg
status "Add updates.img"
umount_dirs
}
function test_updatesimg {
[ -e "$ISODIR/updates.img" ] || fail "Missing updates.img file from iso"
grep "inst.updates=.*updates.img" "$ISODIR/boot/grub2/grub.cfg" || fail "Missing BIOS grub.cfg inst.updates entry"
grep "inst.updates=.*updates.img" "$ISODIR/EFI/BOOT/grub.cfg" || fail "Missing UEFI grub.cfg inst.updates entry"
}
# All of the changes
function run_all {
running "Use all the options"
touch /tmp/updates.img
mkksiso -u /tmp/updates.img -a /etc/services -V "mkksiso-test" -c "console=ttyS0,115200n8" --rm "quiet" --ks $KS $BOOTISO $OUTISO || exit 1
mount $OUTISO $ISODIR || exit 1
test_ks
test_serial
test_volid
test_files
test_updatesimg
test_quiet
status "Use all the options"
umount_dirs
}
# All of the changes as a user (lorax-ted) with --skip-mkefiboot
function run_as_user {
running "Use all the options as a user"
[ ! -e "/home/lorax-ted" ] && useradd -m lorax-ted
touch /tmp/updates.img
su - lorax-ted -c "mkksiso --skip-mkefiboot -u /tmp/updates.img -a /etc/services -V "mkksiso-test" -c "console=ttyS0,115200n8" --rm "quiet" --ks $KS $BOOTISO $OUTISO" || exit 1
mount $OUTISO $ISODIR || exit 1
test_ks
test_serial
test_volid
test_files
test_updatesimg
test_quiet
status "Use all the options as a user with --skip-mkefiboot"
umount_dirs
}
# Gather up the list of system repo files and use them for lorax
REPOS=$(for f in /etc/yum.repos.d/*repo; do echo -n "--repo $f "; done)
if [ -z "$REPOS" ]; then
echo "No system repos found"
exit 1
fi
# NOTE: We must use --nomacboot because the test system doesn't have the hfsplus fs available
# Run lorax using the host's repository configuration file
if [ ! -e "$BOOTISO" ]; then
running "Build boot.iso with lorax"
lorax --product="Fedora" --version=rawhide --release=rawhide --volid="Fedora-rawhide-test" \
$REPOS --isfinal --nomacboot /var/tmp/lorax-fedora-iso/ || exit 1
fi
# Test mkksiso on the new boot.iso
ks_only
ks_pos_only
ks_serial
only_serial
new_volid
add_files
remove_quiet
test_two_kickstarts
add_updatesimg
run_all
run_as_user
exit $FAILANY