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,13 +1,13 @@
|
||||
distro = "fedora"
|
||||
distro = "fedora"
|
||||
version = "37"
|
||||
iso = {
|
||||
url = "https://download.fedoraproject.org/pub/fedora/linux/releases/37/Server/x86_64/iso/Fedora-Server-dvd-x86_64-37-1.7.iso"
|
||||
checksum = "0a4de5157af47b41a07a53726cd62ffabd04d5c1a4afece5ee7c7a84c1213e4f"
|
||||
url = "https://download.fedoraproject.org/pub/fedora/linux/releases/37/Server/x86_64/iso/Fedora-Server-dvd-x86_64-37-1.7.iso"
|
||||
checksum = "0a4de5157af47b41a07a53726cd62ffabd04d5c1a4afece5ee7c7a84c1213e4f"
|
||||
}
|
||||
boot_command = [
|
||||
"<up>e<down><down><end> ",
|
||||
"net.ifnames=0 biosdevnames=0 inst.ks=cdrom:/x86_64.ks console=tty0<f10>"
|
||||
]
|
||||
cd_files = [
|
||||
"distros/fedora/37/*.ks"
|
||||
"distros/fedora/37/*.ks"
|
||||
]
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
distro = "fedora"
|
||||
distro = "fedora"
|
||||
version = "38"
|
||||
iso = {
|
||||
url = "https://download.fedoraproject.org/pub/fedora/linux/releases/38/Server/x86_64/iso/Fedora-Server-dvd-x86_64-38-1.6.iso"
|
||||
checksum = "66b52d7cb39386644cd740930b0bef0a5a2f2be569328fef6b1f9b3679fdc54d"
|
||||
url = "https://download.fedoraproject.org/pub/fedora/linux/releases/38/Server/x86_64/iso/Fedora-Server-dvd-x86_64-38-1.6.iso"
|
||||
checksum = "66b52d7cb39386644cd740930b0bef0a5a2f2be569328fef6b1f9b3679fdc54d"
|
||||
}
|
||||
boot_command = [
|
||||
"<up>e<down><down><end> ",
|
||||
"net.ifnames=0 biosdevnames=0 inst.ks=cdrom:/x86_64.ks console=tty0<f10>"
|
||||
"<up>e<down><down><end> ",
|
||||
"net.ifnames=0 <wait>biosdevnames=0 <wait>inst.ks=cdrom:/x86_64.ks <wait>console=tty0<f10>"
|
||||
]
|
||||
cd_files = [
|
||||
"distros/fedora/38/*.ks"
|
||||
"distros/fedora/38/*.ks"
|
||||
]
|
||||
|
||||
@@ -1,13 +1,13 @@
|
||||
distro = "fedora"
|
||||
distro = "fedora"
|
||||
version = "39"
|
||||
iso = {
|
||||
url = "https://download.fedoraproject.org/pub/fedora/linux/releases/39/Server/x86_64/iso/Fedora-Server-dvd-x86_64-39-1.5.iso"
|
||||
checksum = "2755cdff6ac6365c75be60334bf1935ade838fc18de53d4c640a13d3e904f6e9"
|
||||
url = "https://download.fedoraproject.org/pub/fedora/linux/releases/39/Server/x86_64/iso/Fedora-Server-dvd-x86_64-39-1.5.iso"
|
||||
checksum = "2755cdff6ac6365c75be60334bf1935ade838fc18de53d4c640a13d3e904f6e9"
|
||||
}
|
||||
boot_command = [
|
||||
"<up>e<down><down><end> ",
|
||||
"net.ifnames=0 biosdevnames=0 inst.ks=cdrom:/x86_64.ks console=tty0<f10>"
|
||||
"<up>e<down><down><end> ",
|
||||
"net.ifnames=0 biosdevnames=0 inst.ks=cdrom:/x86_64.ks console=tty0<f10>"
|
||||
]
|
||||
cd_files = [
|
||||
"distros/fedora/39/*.ks"
|
||||
"distros/fedora/39/*.ks"
|
||||
]
|
||||
|
||||
@@ -14,16 +14,16 @@ checksums="${tmp}/checksums"
|
||||
|
||||
# First, find the proper URL, since it updates every build
|
||||
curl -L -o "${listing}" "${fedora}"
|
||||
links="$(cat "${listing}" | pup 'a[href*=".iso"] attr{href}' | grep dvd)"
|
||||
iso_name="$(echo "${links}" | grep -e 'iso$')"
|
||||
links="$(pup -f "${listing}" 'a[href*=".iso"] attr{href}' | grep dvd)"
|
||||
iso_name="$(echo "${links}" | grep -e 'iso$' | head -1)"
|
||||
iso="${fedora}${iso_name}"
|
||||
|
||||
# Read the SHA256 sum value
|
||||
sums="$(cat "${listing}" | pup 'a[href*="CHECKSUM"] attr{href}')"
|
||||
sums="$(pup -f "${listing}" 'a[href*="CHECKSUM"] attr{href}' | head -1)"
|
||||
until curl -f -L -o "${checksums}" "${fedora}${sums}"; do
|
||||
sleep 1
|
||||
done
|
||||
sha="$(cat "${checksums}" | grep dvd | grep SHA256 | cut -d' ' -f 4)"
|
||||
sha="$(grep -e dvd "${checksums}" | grep SHA256 | cut -d' ' -f 4)"
|
||||
|
||||
# Write out HCL file
|
||||
cat << EOF > "${name}"
|
||||
|
||||
Reference in New Issue
Block a user