Do some better linting (#13)
* Do some better linting * Update names, Packer version, and more * Do not lint on push * More linting and scripting * Cleanup shellcheck lint * Add Packer format check * Fix Packer formatting * Limit to only one * Remove generated HCL files * Only lint checked files * Use pipes instead * Improve attempt to build Actually go back to attempting to build boxes on GitHub. Maybe it will work better with this structure * Change to using environment files * Initialize plugins, first * More verbose usage of the file * Do the output properly this time * PACKER_LOG set to 1 * No need for python3 anymore * Limit to only one result * Choose a specific CPU model * Init separately * Update actions version * Add version outputting * Correct actions version * Try to execute qemu properly * Fix CPU model name * Do not over-subscribe GitHub runners * Try type instead of command to guard runs * Do not write to non-existent folder * Cache packer plugins * Use ~ instead of /home/greg * Try the proper path * Move to intelligent matrix * Set global env path * Add lots of waits for VBoxManage on hosted runners * Add more waits * Add more waits
This commit is contained in:
@@ -1,12 +0,0 @@
|
||||
distro = "centos-stream"
|
||||
version = "8"
|
||||
iso = {
|
||||
url = "http://mirror.centos.org/centos/8-stream/isos/x86_64/CentOS-Stream-8-x86_64-latest-boot.iso"
|
||||
checksum = "83fb6025b52ba893669575f7df0048b3adc8e66b4d7c19d8f5522651f19150ba"
|
||||
}
|
||||
boot_command = [
|
||||
"<up><tab><wait><bs><bs><bs><bs><bs>",
|
||||
"inst.text inst.ks=cdrom:/ks.cfg console=tty0",
|
||||
"<enter><wait>"
|
||||
]
|
||||
cd_files = [ "distros/centos-stream/8/disc/*" ]
|
||||
@@ -9,7 +9,7 @@ checksums="$(mktemp)"
|
||||
until curl -f -L -o "${checksums}" "http://mirror.centos.org/centos/8-stream/isos/x86_64/CHECKSUM"; do
|
||||
sleep 1
|
||||
done
|
||||
sha="$(cat "${checksums}" | grep latest-boot | grep SHA256 | cut -d' ' -f 4)"
|
||||
sha="$(grep -e latest-boot "${checksums}" | grep SHA256 | cut -d' ' -f 4)"
|
||||
|
||||
cat << HERPDERP > "${name}"
|
||||
distro = "centos-stream"
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#!/usr/bin/env bash
|
||||
set -ex
|
||||
|
||||
packages="gcc make bzip2 kernel-devel elfutils-libelf-devel"
|
||||
dnf install -y ${packages} # Intentionally not quoted
|
||||
packages=(gcc make bzip2 kernel-devel elfutils-libelf-devel)
|
||||
dnf install -y "${packages[@]}"
|
||||
mount -t auto /home/vagrant/VBoxGuestAdditions.iso /mnt
|
||||
/mnt/VBoxLinuxAdditions.run install --nox11 2>&1 | tee /root/vbox_addon_install.log
|
||||
umount /mnt
|
||||
|
||||
@@ -1,12 +0,0 @@
|
||||
distro = "centos-stream"
|
||||
version = "9"
|
||||
iso = {
|
||||
url = "https://mirror.stream.centos.org/9-stream/BaseOS/x86_64/iso/CentOS-Stream-9-latest-x86_64-boot.iso"
|
||||
checksum = "2553e0812dba592ae4f73a06105eec1a285623c9ae790a5674456eed1ce9dc4c"
|
||||
}
|
||||
boot_command = [
|
||||
"<up><tab><wait><bs><bs><bs><bs><bs>",
|
||||
"inst.text inst.ks=cdrom:/ks.cfg console=tty0",
|
||||
"<enter><wait>"
|
||||
]
|
||||
cd_files = [ "distros/centos-stream/9/disc/*" ]
|
||||
@@ -10,7 +10,7 @@ checksums="$(mktemp)"
|
||||
until curl -f -L -o "${checksums}" "${baseurl}.SHA256SUM"; do
|
||||
sleep 1
|
||||
done
|
||||
sha="$(cat "${checksums}" | awk '/SHA256/ {print $4}')"
|
||||
sha="$(awk '/SHA256/ {print $4}' "${checksums}")"
|
||||
rm "${checksums}"
|
||||
|
||||
cat << HERPDERP > "${name}"
|
||||
@@ -22,7 +22,7 @@ iso = {
|
||||
}
|
||||
boot_command = [
|
||||
"<up><tab><wait><bs><bs><bs><bs><bs>",
|
||||
"inst.text inst.ks=cdrom:/ks.cfg console=tty0",
|
||||
"inst.text <wait>inst.ks=cdrom:/ks.cfg <wait>console=tty0",
|
||||
"<enter><wait>"
|
||||
]
|
||||
cd_files = [ "distros/centos-stream/9/disc/*" ]
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#!/usr/bin/env bash
|
||||
set -ex
|
||||
|
||||
packages="bzip2 kernel-devel kernel-headers make perl gcc"
|
||||
dnf install -y ${packages} # Intentionally not quoted
|
||||
packages=(bzip2 kernel-devel kernel-headers make perl gcc)
|
||||
dnf install -y "${packages[@]}"
|
||||
mount -t auto /home/vagrant/VBoxGuestAdditions.iso /mnt
|
||||
/mnt/VBoxLinuxAdditions.run install --nox11 2>&1 | tee /root/vbox_addon_install.log
|
||||
umount /mnt
|
||||
|
||||
Reference in New Issue
Block a user