* Make sure test doesn't break when master matches the latest release
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Point to existing artifacts for 2.5.0 release
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Bump download-artifact action
to hopefully fix the error:
```
Preparing to download the following artifacts:
- kairos-alpine-3.19.iso.zip (ID: 1164540479, Size: 1053840217)
Redirecting to blob download url: https://productionresultssa4.blob.core.windows.net/actions-results/e30c4747-a895-4fc2-a9ad-5c3c721fbe5c/workflow-job-run-54b5a70f-2f08-532f-96ed-a371e24f143d/artifacts/kairos-alpine-3.19.iso.zip.zip
Starting download of artifact to: /runner/_work/kairos/kairos
(node:1192) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
Error: Unable to download artifact(s): Unable to download and extract artifact: Artifact download failed after 5 retries.
```
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
---------
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Use kairos-agent instead of naming.sh everywhere
For this commit, kairos-agent has to be built from at least 4409a4e
Also:
- Remove some relics from when we had docs in this repo and when we
used to pass a VERSION to the bundle for systemd-sysext (now we use
"_ANY")
- Simplify earthly targets. They don't need all that input just to construct
the artifact name because it's running on the "base-image".
The artifact name is already written in the /etc/os-release file.
- Remove +version target and convert GIT_VERSION to a normal target because when you call
`DO +foo` in a target and "foo" has "FROM myimage" in it, after the call, your
target now runs on "myimage".
- Remove "VERSION" instances from most places, except in reusable-build-flavor
which is using it to replace it with "latest" thus the current value
(just the kairos version) should work. That workflow is disabled currently
but I tried not to break it in case someone re-enables it.
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Fix rebase mistake
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Fix issues building arm
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Oops
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
Co-authored-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Use framework images built on new repo
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Luet is not in the framework anymore
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Use latest release by default
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* remove concept of security profile
Generic images don't reflect it anymore so this can be considered part of the version
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Check for failures faster and make sure bundles don't break
It should fail now because of this fix needed:
https://github.com/kairos-io/kairos-agent/pull/174
After bumping to the fixed kairos-agent version, the test should be
green again.
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* ⬆️ Update repositories
Signed-off-by: GitHub <noreply@github.com>
* Bump osbuilder to produce a livecd with tty1 as default console
Grub configuration for livecd (iso) is installed here:
89b014b2b2/tools-image/Dockerfile (L25)
and it repositories were bumped in osbuilder to use the latest and
updates grub configuration where `console=tty1` is set **after**
`console=ttyS0` thus making it the default console for systemd services.
Also:
- remove not used bootargs.cfg file (has been moved to the "packages"
repo)
- Change to the DATASOURCE check which is what we need in reality (not
CLOUD_INIT which was indirectly checking that DATASOURCE would be set
by Earthly)
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Double the waiting time until installation is finished
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Triple the timeout (it passses locally, just needs time)
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Bump luet repository to get kairos-agent 2.4.2
which has this fix: https://github.com/kairos-io/kairos-agent/pull/174
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Revert to the old test logic
which, in case of errors, will fail with a timeout but kairos service
doesn't allow us to know when the installer is done. That's because
the service has `RemainAfterExit=yes` and even if that was removed, the
kairos process waits for user input to finish:
```
Installation completed, press enter to go back to the shell. [Yes/no/all/cancel]
```
so there is not sure way to tell whether the kairos installer failed
with or without errors.
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
---------
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
Signed-off-by: GitHub <noreply@github.com>
Co-authored-by: jimmykarily <jimmykarily@users.noreply.github.com>
* Fix arch name in arm artifacts
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Update test to use new artifact names
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Fix name of security results
Fix test when calling without ISO
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Introduce RHEL family
- merges the files for rockylinux and almalinux into a rhel dockerfile
- decided not to add fedora into this since, it requires to add the epel packages, which might make fedora too close to rhel for our community users. But wonder what you think, is it a good/bad idea to try to also merge that one?
Clean up fedora dockerfile
- remove packages which are already installed by default "coreutils" and "curl"
- make it similar to the other dockerfiles for easier maintenance
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Add fedora to rhel family
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Introduce inbetween stage for readability
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Install the right k3s package based on the init system
Fixes: #1797
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Bump luet repository to use the new packages
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Add FLAVOR ARG for consistency
although it's a global and it should work anyway. But we pass it in
other places so let's at least be consistent.
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
---------
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* 🎨 Bundle bootargs with framework images
Currently bootargs is not provided with the framework images so its
missing a very important piece to boot which results into BYOI being
broken.
This patch adds the bootargs.cfg to the framework image. Also the
config.txt to the rpi images.
Also drops the kernel/initramfs vars from the bootargs as they are set
to the default now in the package.
Also moves the luet clean under the package list generation as it
requires the database of luet to list the packages.
Signed-off-by: Itxaka <itxaka@kairos.io>
* Bump repos
Signed-off-by: Itxaka <itxaka@kairos.io>
* 🤖 Do not download the generated iso for upgrade-latest
Its not needed, we boot from latest release and upgrade to pushed
container, the iso is not touched
Signed-off-by: Itxaka <itxaka@kairos.io>
* 🎨 Restore kernel/initramfs values
Needed for upgrade as we dont upgrade COS_GRUB partition with anything
new during upgrade so we are stuck with existing config in there during
upgrades
Signed-off-by: Itxaka <itxaka@kairos.io>
---------
Signed-off-by: Itxaka <itxaka@kairos.io>
* 🤖 Use prebuilt iso on zfs test
Due to a mixup in the dirs, the zfs test was not finding the prebuilt
iso and was constructiing a new one on each run
Signed-off-by: Itxaka <itxaka@kairos.io>
* Do not run reset test twice
Just to check a simple grubenv file, just run it once as running it
twice means that we would drop the machine adn start from scratch again,
which makes no sense for a simple test.
Signed-off-by: Itxaka <itxaka@kairos.io>
---------
Signed-off-by: Itxaka <itxaka@kairos.io>
As we use the state/recovery partition for storing the transition image
during upgrades, on ubuntu the partition sizes did not allow to store
the image properly as they were too small.
This fixes the current sizes for ubuntu based rpi64 images
Signed-off-by: Itxaka <itxaka@kairos.io>
* Bring back the bootargs.cfg files to the base image
because we need them before any stages are run (grub needs them)
Related PR that removes them from the luet package:
https://github.com/kairos-io/packages/pull/391
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* Change the dockerfile build context
to make COPY commands work without knowledge of the kairos repository
directory structure.
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Bump luet repo
to get this:
https://github.com/kairos-io/packages/pull/391
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* COPY, don't RUN files
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Bump luet repo
to get this:
https://github.com/kairos-io/packages/pull/392
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
---------
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
Co-authored-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Add k3s version when it is set
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Make K3S_VERSION a global
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Remove luet rebuild numbers from k3s version
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
---------
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* 🐧 Separate rpi3 from rpi4
Signed-off-by: Itxaka <itxaka@kairos.io>
* 🤖 Change the rpi64 to rpi4 for ci
Signed-off-by: Itxaka <itxaka@kairos.io>
* Rework dockerfiles for rpi3/4 separation
Signed-off-by: Itxaka <itxaka@kairos.io>
* Run arm PR in kvm runners
Signed-off-by: Itxaka <itxaka@kairos.io>
* Bump osbuilder and run under fast runner
Signed-off-by: Itxaka <itxaka@kairos.io>
---------
Signed-off-by: Itxaka <itxaka@kairos.io>
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
to distinguish between distro and flavor without making reference to model and arch within the flavor
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Use dev version for provider kairos in Earthly
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* [WIP] Build a matrix for standard (provider) images
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Build provider-kairos image with the right flags
E.g. Invoke it as:
earthly +iso -PROVIDER_KAIROS=true -PROVIDER_KAIROS_VERSION=2.3.0 -K3S_VERSION=1.24.2
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Use latest package for provider-kairos and k3s
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Remove PROVIDER_KAIROS_VERSION setting
because when we install with luet, the version is defined by the
repository in framework-profile.yaml
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Remove implemented TODO
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Construct the k8s versions by quering the luet repo for available ones
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* No need to change version strings
They are already in the required format for luet
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* WIP
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Remove default MODEL that doesn't work
because the top level default always wins (Earthly...)
and downgrade osbuilder because it breaks arm builds. This should fix it:
https://github.com/kairos-io/osbuilder/pull/80
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Don't build standard images for nvidia jetson
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* WIP
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Drop PROVIDER_KAIROS and use VARIANT=standard instead
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* WIP
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* WIP
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* WIp
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Remove not used ARGs and simplify targets
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* Try out on our branch
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Configure luet before searching it
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* Try to fix luet
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Fix luet
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Fix signing path
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Bump CI
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Add debug job
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Remove dummy job and try to remove permissions
to see if they are actually needed anywhere
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Debug, debug, debug
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Switch back to old naming
we will deal with it on another PR
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Simplify jq syntax
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* Fix arm image release pipeline (no generic yet)
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Fix luet installation in job
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* Fix the release-arm pipeline
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Unshallow the checkout in the pipeline to build a proper VERSION
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* Use the action fetch-depth instead of unshallow
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Fix earthly things
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* WIP
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Remove our test branch from the workflow
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Remove done TODOs and make sure we install tools in all k3s versions
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* Rename Earthly command and remove unnecessary copying
because the framework-profile should already be in place
(Fixes based on PR comments)
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Add nohang in base images (wherever it's available)
and remove the Earthly target for that.
Question: We only enable this on systemd:
https://github.com/kairos-io/kairos/blob/master/overlay/files/system/oem/09_services.yaml#L21-L22
What about systemd flavors that don't have it? (fedora, rockylinux,
almalinux)
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Add repository for nohang in jetson dockerfile
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Filter which flavors to build standard image for
and stop running the release pipeline our current branch
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
* Fix name of matrix
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
---------
Signed-off-by: Dimitris Karakasilis <dimitris@karakasilis.me>
Signed-off-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
Co-authored-by: Mauro Morales <mauro.morales@spectrocloud.com>
Co-authored-by: Dimitris Karakasilis <dimitris@spectrocloud.com>
* 🐧 Increase image size for Orin images
Signed-off-by: Ettore Di Giacinto <mudler@kairos.io>
* 🐧 Add cublas/opencv to Jetson Orin images
Signed-off-by: Ettore Di Giacinto <mudler@kairos.io>
* 🐛 workaround /usr/local shadowed files
Signed-off-by: Ettore Di Giacinto <mudler@kairos.io>
* 🐧 Increment default image size in the agent
Signed-off-by: Ettore Di Giacinto <mudler@kairos.io>
* 🐛 use `initramfs.before`
Signed-off-by: Ettore Di Giacinto <mudler@kairos.io>
* 🐧 Add vim to orin images
Signed-off-by: Ettore Di Giacinto <mudler@kairos.io>
* Address feedback from review and clean up package list
Signed-off-by: mudler <mudler@kairos.io>
---------
Signed-off-by: Ettore Di Giacinto <mudler@kairos.io>
Signed-off-by: mudler <mudler@kairos.io>
- Only build iso+image
- Only upload sarif and sboms on master merge
- Do not upload anything but ISO on PRs
- Only upload iso+image+sarif+sbom on master merge
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* 🐧 add grub2 symlink to the orin image
Signed-off-by: mudler <mudler@mocaccino.org>
* 🐛 Copy ubuntu arm artifacts into orin images
Signed-off-by: mudler <mudler@mocaccino.org>
* Update Earthfile
Co-authored-by: Mauro Morales <mauro.morales@spectrocloud.com>
Signed-off-by: Ettore Di Giacinto <mudler@users.noreply.github.com>
Signed-off-by: mudler <mudler@mocaccino.org>
* 🌱 move framework preparation to a script
Signed-off-by: mudler <mudler@mocaccino.org>
* 🌱 run dracut only when its present in the image
Signed-off-by: mudler <mudler@mocaccino.org>
* Revert "🌱 move framework preparation to a script"
This reverts commit 025ffa248434bc49baf1f91c7105e04c6d3ee0b4.
Signed-off-by: mudler <mudler@mocaccino.org>
* try to keep things on earthly
Signed-off-by: mudler <mudler@mocaccino.org>
---------
Signed-off-by: mudler <mudler@mocaccino.org>
Signed-off-by: Ettore Di Giacinto <mudler@users.noreply.github.com>
Co-authored-by: Mauro Morales <mauro.morales@spectrocloud.com>
* WIP image
Signed-off-by: mudler <mudler@mocaccino.org>
* Add nvidia overlay files
Signed-off-by: mudler <mudler@mocaccino.org>
* fixups, add to pipelines
Signed-off-by: mudler <mudler@mocaccino.org>
* lint fixes
Signed-off-by: mudler <mudler@mocaccino.org>
* ci: workaround Earthly parallelism
Signed-off-by: mudler <mudler@mocaccino.org>
* ci: nuke more space from public workers
Signed-off-by: mudler <mudler@mocaccino.org>
* ci: try to run on self-hosted
Signed-off-by: mudler <mudler@mocaccino.org>
* ci: add comment
Signed-off-by: mudler <mudler@mocaccino.org>
* ci: use mirror in ARM jobs
Signed-off-by: mudler <mudler@mocaccino.org>
* Run with docker
Signed-off-by: mudler <mudler@mocaccino.org>
* run some jobs on self-hosted
Signed-off-by: mudler <mudler@mocaccino.org>
* cleanup if on public runners
Signed-off-by: mudler <mudler@mocaccino.org>
---------
Signed-off-by: mudler <mudler@mocaccino.org>
* Expand size for ubuntu arm images
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Expand size of active partition for ubuntu arm rpi
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* added initial Dockerfile for ubuntu-arm-rpi flavor
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* added Dockerfiles for the other ubuntu arm rpi flavors
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* added overlay files for ubuntu-arm-rpi
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* propagate new flavor ubuntu-arm-rpi through repo
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* propagate ubuntu-20-lts-arm-rpi and ubuntu-22-lts-arm-rpi through the repo
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* ubuntu-20-lts-arm-rpi: use the correct firmware package
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* use dracut-network-legacy-compat for all ubuntu lts flavors
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* one package per line for rpi ubuntu dockerfiles
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* some cosmetic changes on the rpi dockefiles
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* removed unnecessary network interface files from dockerfile
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* hadolint: ignore apt pinned version and missing no-install-recommend for now
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* added explicit systemd-timesyncd to rpi dockerfiles
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* removed more unneeded apt-get clean from dockerfiles
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* minor name corrections and removing commented out stuff
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Change sizes for rpi ubuntu images
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Lint
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* This was fixed on #821
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Keep use of cos instead of kairos in bootargs.cfg
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Add ports to RPi Docker images
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Force platform arm64 on all-arm target
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Use model to generate the generic ubuntu arm image
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* lint and apply changes to other ubuntu versions
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* force platform and model for all-arm
fix issues with ubuntu 20 lts arm rpi
remove unnecessary dockerfile
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Add missing reference in dockerfiles
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Increment trivy timeout
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Update packages for 20.04
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Remove dl3015
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Fix issue with ubuntu arm rpi overlay files
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Refactor overlay files for rpi
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Part of last commit
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Pass model to framework
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* No need to have a different persistency config for the rpi
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Disable rpi-eeprom-update
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* review feedback
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
Co-authored-by: Martin Schuessler <1407812+c0ffee@users.noreply.github.com>
* Remove duplication of kairos vars in os-release
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Use temp file
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Use sed to avoid using a temp file
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* ✨ Use kairos-agent from packages
Also drops all uneeded targets, code and so on for the agent
Moves profile-build into its own dir
Moves go.mod files into theyr own, one for testing and one for the
profile build
Adjusts earthly targets to the new stuff
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Bump repos and rework earthfile for kairos-agent package
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Restore missing earthly scripts
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Run apt update before apt install
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Copy go.{mod,sum} to local dir before tests
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Fix install tests
Is the only one not run in earthly, strange.
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
---------
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Use site variables to update image flavor and name
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Typo
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Prefix variable names with distro name in os-release
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Adapt tests to read os-release with prefix
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Adapt docs to show how to read os-release with prefix
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Update SDK to be aware of attr prefixes
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Adapt test with new variable names
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Temporarily print the os-release
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Check KAIROS_VERSION on tests and fallback to VERSION
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Match kubo ID and VERSION_ID
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Make kubo extension match any ID
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Test still fails, trying with surrounding quotes
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Reduce tests wait time
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Use tumbleweed for bundles tests
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Update docs about systemd-sysext
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* reduce wait time in reset tests
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
🌱 Generate arm64 generic isos
- Use latest osbuilder tools image as it contains fixes for arm64 isos
- Add a small job to build an iso as part of the image arm workflow
- Rework /boot/vmlinuz linking so it works on x86 and arm64
This also adds an iso-remote target for earthfile that allows to build
an iso from a remote rootfs in the shape of a docker artifact. This
allows for easy reproduce of isos based on existing artifacts instead of
having to rebuild the whole thing. You point to the artifact and it
spits an iso really fast. Also works with arm64 artifacts so we can
easily build a local arm64 iso for testing for pushed artifacts.
This PR makes it so generation of isos for arm64 works.
Signed-off-by: Itxaka <itxakaserrano@gmail.com>
* Pass VERSION flag including v2 in path
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Pass VERSION flag including v2 in path for goreleaser
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Add version to goreleaser
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* do not remove github token
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* include version in dist target
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Add missing flag to pass the version
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Bump go in Earthly and workflows to ^1.20
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Update go.mod version
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Lint
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Remove pin of go version to get the latest
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* Remove minor version
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
---------
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
* 🐛 Fix validator on long strings
Validator was mistakenly identifying a long yaml as a file and trying to
open it, which failed with an error of filename too long.
This was not catched in order to identify that the source is not a file
but a yaml, so it was directly returning the error.
This patch adds that error to the list in order ot identify the source
to validate as yaml. Also adds a couple of tests for this functionality.
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* 🐛 Merge initramfs generation between distros
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
---------
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
We were listing on a dir that now doesn't exist necessarly anymore, and
when picking up the iso from latest release, we are selectively
pickingone flavor for the upgrade test.
Signed-off-by: mudler <mudler@c3os.io>
* ⚠️🎨✨ Use immucore
Build kairos with immmucore instead of cos-immutable-rootfs
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* 🐛 Fix state sdk
State sdk is using ghw to identify the state of the disks, but
unfortunately ghw only works with devices and not with labels
This patch adds a workaround by checking deeper for partitions that
migth not have mountpoints reported by ghw but are indeed mounted
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* 🐛 Fix state not catching netboot properly
This worked with the old cos-immutable-rootfs due to the rd.cos.disable
stanza in cmdline making the livecd cloud config file trigger, which
created the livecd sentinel file.
With immucore, the sentinel is being created during initramfs directly
so we need to rely on the cmdline to identify it.
State sdk should know that having the netboot stanza should identify the
boot as cdlive
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Fix custom binds set as RW_PATHS
RW_PATHS are meant for overlay dirs which go away after a reboot.
Custom binds/binds are mounted under COS_PERSISTENT, so they persist
after reboot AND are RW by default.
This patch removes adding the custom binds into the RW_PATHS on the
cos-layout file as that can lead to unintended consequences
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Dont run custom mounts on livecd and recovery
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Rework writing custom ephemeral/binds
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Maybe fix tests
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* Add missing sgdisk to ubuntu images
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
* 🐛 Backport dracut patch for ubuntu 20 iscsi
There was an issue with dracut 48 in which the iscsid.socket required fs
targets to be ready. On an iso this could lead to a dependency cycle
between the dmsquash module setting up the livecd rootfs and the iscsi
socket required the initrd-fs to be ready.
This was fixed on dracut 50 and its what this patch brings, dropping the
socket dependency on the fs target so it can break the dependency cycle.
This only affect ubuntu 20 lts, and only affects booting from the iso.
Alos the issue is random as systemd will decide to break the dependency
in a non predictable way by disabling one of the services that conflict,
so sometimes it would be the iscsi serviec, which would make the iso
boot but sometimes it could be other more important services liek teh
local fs or the dracut pre-mount services.
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
(cherry picked from commit 63f0c75d69)
* Bump immucore
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
---------
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
Co-authored-by: Ettore Di Giacinto <mudler@users.noreply.github.com>
* 🐛 Add back gdisk to ubuntu/debian images
Signed-off-by: mudler <mudler@c3os.io>
* 🤖 No need to install mkisofs here
Signed-off-by: mudler <mudler@c3os.io>
---------
Signed-off-by: mudler <mudler@c3os.io>
Currently is done during docker image but it makes no sense, it should
be during framework otherwise framework images do not contain the binary
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
Add temp-image Earthly target
This is helpful to quickly generate temp images and upload them to
ttl.sh plus you can quickly distinguish the images by branch and sha
Signed-off-by: Mauro Morales <mauro.morales@spectrocloud.com>
Add docker versioning for the `RENOVATE_VERSION`
This isn't being picked up in the dashboard (#310), and it might be
because `34` isn't a proper semver.
Signed-off-by: Shawn Wilsher <656602+sdwilsh@users.noreply.github.com>
Mange the version of quay.io/kairos/osbuilder-tools with renovate
This should trigger an update in short order as the current version of
this image is v0.5.2.
Signed-off-by: Shawn Wilsher <656602+sdwilsh@users.noreply.github.com>
Now that the config is more than the stock config, and folks are
interested in using it more, we should have some automation to verify
that the config is valid.
Signed-off-by: Shawn Wilsher <656602+sdwilsh@users.noreply.github.com>
Have renovate manage image versions in `Earthfile`
This change adds support for renovate to be able to update the versions
of `quay.io/luet/base`, `golang`, and `hadolint`.
Signed-off-by: Shawn Wilsher <656602+sdwilsh@users.noreply.github.com>
* 🔧 merge custom mounts tests
Since the feature is now merged, we no longer need
a single label for this. This saves a few CI cycles.
To acheive this, we add the correct sections to the normal
install sections and assert that these paths exist.
The previous assertions are kept, but in order to make
code a bit more readable, I extracted the anonymous function
that collects the data from the installed VM.
Instead of repeating the installation 4 times, we now only
repeat the installation 2 times.
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Refactor tests
Works with VBox, fails with QEMU
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Fix cloud-config identation
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
---------
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Pull out golint into its own target
Signed-off-by: Shawn Wilsher <656602+sdwilsh@users.noreply.github.com>
* run hadolint on the Docker files in images/
Signed-off-by: Shawn Wilsher <656602+sdwilsh@users.noreply.github.com>
* Ignore existing failures of hadolint, at least for now
Signed-off-by: Shawn Wilsher <656602+sdwilsh@users.noreply.github.com>
---------
Signed-off-by: Shawn Wilsher <656602+sdwilsh@users.noreply.github.com>
Looks like there was missing docs for the --keep-own flag on easrthly
and we can indeed keep permissions for all dirs/files when copying
artifacts, but the flag needs to be both on the SAVE ARTIFACT and in the
COPY stanzas.
Signed-off-by: Itxaka <itxaka@spectrocloud.com>
Signed-off-by: Itxaka <itxaka.garcia@spectrocloud.com>
Co-authored-by: Itxaka <itxaka@spectrocloud.com>
* ✨ custom user bind and ephemeral mounts
Users can now specify custom and ephemeral mounts in cloud-init under
the `install` section, e.g.:
```
users:
- name: kairos
...
install:
auto: true
device: "auto"
bind_mounts:
- /mnt/bind1
- /mnt/bind2
ephemeral_mounts:
- /mnt/ephemeral
- /mnt/ephemeral2
...
```
Ephemeral mounts are mounted as RW - but changes are discarded when the
machine is restart.
Bind mounts will persist changes after restarted.
This is a fix for #210
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Add the custom user mount to /cos/run/cos-layout.env
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Add docs for custom user mounts in configuration example
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Reuse test_install function
DRY the code, change how we call the function install_test
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Enable custom mount tests and install tests
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Enable tests in CI
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Remove duplicate if check
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Remove uneeded fmt.Println ...
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Use separate label for custom mounts
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* 🔧 Earthfile - DRY ginkgo
We repeat this a more than twice so just extract to own
target...
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Correct return type for ContainElements
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Remove CLOUD_INIT from custom mounts test
This is not needed here.
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* Fix qemu-test-* earthly targets
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* 🔧 Fix CPU passing to VM
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* 🔧 remove apt cache after install qemu
Helps deal with space running out in the CI.
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
* 📖 Document custom mounts
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
---------
Signed-off-by: Oz Tiram <oz@spectrocloud.com>
Co-authored-by: Ettore Di Giacinto <mudler@users.noreply.github.com>
Space gained is negligible, just a few Kbs usually (with gzip as its
currently) but the speed up improvements in building the ISO are really
good, for 20 seconds to 40 seconds per ISO build, and that gets more accentuated
on CI runs where the runners are more CPU constrained.
Signed-off-by: Itxaka <itxaka@spectrocloud.com>
Co-authored-by: Itxaka <itxaka@spectrocloud.com>
Looks like a ] was missing and instead of crashing and burning, earthly
continued happily, which meant that on v1.5.0 ARM tumbleweed images the
initrd is missing as earthly failed to parse the check but did not
errored out.
Signed-off-by: Itxaka <itxaka@spectrocloud.com>
Co-authored-by: Itxaka <itxaka@spectrocloud.com>
* ✨ add tumbleweed flavor
- Adds new opensuse-tumbleweed and opensuse-tumbleweed-arm-rpi flavors
- Renames opensuse to opensuse-leap
- Adapt earthfile to new names
- Adapt CI to new names
- Drop uneeded argument from dockerfiles
- Updates docs to point older core-opensuse mentions to new
core-opensuse-leap flavor.
- Add core-opensuses-tumbleweed flavor to matrix of version
- Point to new kairos provider repos which include the version in the
naming
Signed-off-by: Itxaka <itxaka@spectrocloud.com>
No Need to generate the sha sum for the iso manually, elemental already does it
Signed-off-by: Itxaka <itxaka@spectrocloud.com>
Signed-off-by: Itxaka <itxaka@spectrocloud.com>
Co-authored-by: Itxaka <igarcia@suse.com>