28 Commits

Author SHA1 Message Date
Harald Sitter
24eda82e5f consume caibx file via sysupdate
this is a bit dangerous but necessary for more efficient delta updates.

we must be very careful to avoid a bug in systemd caused by putting
foo.erofs.caibx into the sha256sums. so instead we have foo.caibx that
gets installed with the correct name by sysupdate

we still have the foo.erofs.caibx on the server for backwards compat,
but continue to not put it into the sha256sums
2025-09-17 14:17:24 +02:00
Harald Sitter
2d8dca8329 move sha256sums to sysupdate dir
systemd doesn't like subdir references in the sha256sums so we can't
have a single sums file in the root but rather need to have multiple
2025-08-21 01:15:10 +02:00
Harald Sitter
5653cd0db6 try to invoke scp correctly 2025-08-20 20:31:09 +02:00
Harald Sitter
d532605483 comment++ 2025-08-20 19:51:07 +02:00
Harald Sitter
8c51beb068 shell glob please 2025-08-20 19:49:15 +02:00
Harald Sitter
c5be947571 upload sysupdate artifacts to a versioned directory
helps with implementation of a banana split

https://community.kde.org/KDE_Linux/Banana_Split
2025-08-20 18:54:27 +02:00
Harald Sitter
5ed5b5d752 yet more caibx hotfixing 2025-08-17 01:30:40 +02:00
Harald Sitter
c21666a893 don't put the caibx into the shasums
it breaks matching on the erofs somehow such that systemd downloads the
caibx thinking it is the erofs
2025-08-14 22:09:09 +02:00
Harald Sitter
3f455168d7 generate a desync index for the erofs
allows to desync... in theory anyway
2025-08-14 20:47:46 +02:00
Harald Sitter
ce0649c129 make upload more verbose
it gets stuck on the VM based CI and it's not clear why
2025-07-30 18:02:57 +02:00
Harald Sitter
64841b3ebb files are owned by root because we sudo. take them back 2025-07-30 12:20:03 +02:00
Harald Sitter
d1a627607c try to make sure the uploader has access
not sure why that is being weird after the VM transition. let's see if a chown fixes it
2025-07-30 11:50:04 +02:00
Harald Sitter
20bda00747 create an erofs of the rootfs as well
we might end up using it instead of a btrfs subvolume. first we need one
to experiment with though
2025-03-20 00:57:33 +00:00
Ian Monroe
1921a0140c Revert "Use mkosi.output for build artifacts"
This reverts commit ea7ca55cd2.
2024-12-16 11:34:28 -08:00
Bruno Pajdek
ea7ca55cd2 Use mkosi.output for build artifacts
mkosi already provides us with a nice default directory it puts artifacts in called `mkosi.output` if `--output-directory` isn't explicitly set. For some reason, it _is_ explicitly set to `.`, so it puts them in the source tree itself which pollutes it and gets messy real quick.

After build, the contents of the source tree are now
```
drwxrwxrwx 1 root root  100 Dec 15 15:18 .git
-rw-rw-rw- 1 root root  226 Dec 15 15:18 .gitignore
-rw-rw-rw- 1 root root 1.1K Dec 15 15:18 .gitlab-ci.yml
drwxrwxrwx 1 root root  370 Dec 15 15:18 LICENSES
-rw-rw-rw- 1 root root  337 Dec 15 15:18 README.md
-rw-rw-rw- 1 root root  128 Dec 15 15:18 REUSE.toml
-rwxrwxrwx 1 root root  824 Dec 15 15:18 addons.sh
-rwxrwxrwx 1 root root 1.7K Dec 15 15:18 bootstrap.sh
-rwxrwxrwx 1 root root 6.1K Dec 15 15:18 build.sh
-rwxrwxrwx 1 root root 2.9K Dec 15 15:18 build_docker.sh
-rwxrwxrwx 1 root root  427 Dec 15 15:18 in_docker.sh
drwxrwxrwx 1 root root   96 Dec 15 15:25 kde-linux.cache
drwxrwxrwx 1 root root   20 Dec 15 15:18 mkosi.cache
-rw-rw-rw- 1 root root 1.8K Dec 15 15:18 mkosi.conf
drwxrwxrwx 1 root root  420 Dec 15 15:18 mkosi.conf.d
drwxrwxrwx 1 root root   20 Dec 15 15:18 mkosi.extra
-rwxrwxrwx 1 root root 3.6K Dec 15 15:18 mkosi.finalize.chroot
drwxr-xr-x 1 root root  500 Dec 15 15:37 mkosi.output
-rwxrwxrwx 1 root root 5.2K Dec 15 15:18 mkosi.postinst.chroot
-rwxrwxrwx 1 root root 1.3K Dec 15 15:18 mkosi.prepare.chroot
drwxrwxrwx 1 root root   46 Dec 15 15:18 mkosi.repart
drwxrwxrwx 1 root root    6 Dec 15 15:18 mkosi.skeleton
-rwxrwxrwx 1 root root  742 Dec 15 15:18 permission-fix.sh
drwxrwxrwx 1 root root   30 Dec 15 15:18 strip
-rwxrwxrwx 1 root root 1.4K Dec 15 15:18 torrent-create.rb
-rwxrwxrwx 1 root root  796 Dec 15 15:18 update.sh
drwxrwxrwx 1 root root   94 Dec 15 15:18 upload-vacuum
-rwxrwxrwx 1 root root 1.6K Dec 15 15:18 upload.sh
```

And the contents of `mkosi.output` are
```
drwxr-xr-x 1 root root  206 Dec 15 15:28 kde-linux_202412151518
-rw-r--r-- 1 root root 173M Dec 15 15:25 kde-linux_202412151518.efi
-rw-r--r-- 1 root root 5.2G Dec 15 15:36 kde-linux_202412151518.raw
-rw------- 1 root root  55K Dec 15 15:37 kde-linux_202412151518.torrent
-rw-r--r-- 1 root root  14M Dec 15 15:25 kde-linux_202412151518.vmlinuz
-rw-r--r-- 1 root root 1.6G Dec 15 15:23 kde-linux_202412151518_debug-x86-64.tar.zst
-rw-r--r-- 1 root root 173M Dec 15 15:24 kde-linux_202412151518_live.efi
-rw-r--r-- 1 root root 3.0G Dec 15 15:36 kde-linux_202412151518_root-x86-64.tar.zst
```
2024-12-15 17:55:10 +00:00
Harald Sitter
ce692b289f create torrent file for raw image 2024-11-06 02:01:01 +01:00
Harald Sitter
c850a863e9 vacuum: generate sha256sums from server data
that way we don't have extranous entries in there
2024-11-05 00:19:32 +01:00
Harald Sitter
5da433f90b refine comment a tad 2024-11-03 19:30:05 +01:00
Harald Sitter
38ada50675 use correct base dir
SRCDIR is only defined inside the mkosi stage
2024-11-03 19:29:57 +01:00
Harald Sitter
3012a6714a more host changes to use the origin host 2024-11-03 19:01:20 +01:00
Harald Sitter
54c61907a1 make sure to upload to the right server
files.kde.org geo-redirects, what we need is the actual origin server
2024-11-03 18:51:11 +01:00
Harald Sitter
bc35596bd2 gpg: use more consistent key names 2024-11-03 18:37:34 +01:00
Harald Sitter
077ce58c2e try to get gpg signing going 2024-11-03 18:02:05 +01:00
Harald Sitter
a9b2fa6851 keep the key secure 2024-10-10 02:07:53 +02:00
Harald Sitter
41b14fcdf7 set known_hosts for scp
in retrospect I probably should have just written all of this in go -.-
2024-10-10 00:29:33 +02:00
Harald Sitter
7248df97b6 update variables to new names
and -u so it exits when variables are undefined
2024-10-09 20:50:54 +02:00
Harald Sitter
2a26e15594 move uploads to files.kde.org
this requires that we vacuum uploads automatically so there's a helper
for that now. hopefully it works :D
2024-10-09 17:22:38 +02:00
Harald Sitter
42ed5696a9 grand refactor
- add ci builds
- add some scripting surrounding spinning up local containers
- use btrfs send-receive to populate the image for both speed, precision
and reliablity (won't miss ENSPC or something)
- no longer generate bootable images through mkosi, we generate two UKIs
anyway, mkosis extra work is entirely pointless and as it turns out
produces vastly larger UKIs for some reason. probably worth inspecting
at some point why that is
- the entire build has been moved from relying on arch packages to using
kde-builder. this effectively turns the way we build in development also
in the way we build for deployment, giving greater familiarity and
exercise of code paths
- move initrd from dracut to mkinitcpio as it is better integrating with
the arch base
- the initrd system is still driven by systemd rather than busybox (the
initcpio default)
- calamares tech still doesn't work entirely but got a bit of polish
- basic session blessing support (tracking whether an image is good or
not)
- boot failure tracking via the UKI filename (foo_1+3-1.efi etc)
- pam files imported from arch
- font files imported from neon
- aggressive debugging via systemd is on for the time being to aid with
development
- snapd support
- general AUR support (really cruddy because we are inside a bwrap that
runs with no-new-priviledges which means we can't sudo but arch tools
don't want to run as root - so everything is awkwardly detangled with
dependency installation happening manually in root scope, then the build
as a temporary user, then the installation in root scope again)
-
2024-03-13 19:48:30 +01:00