Commit Graph

8377 Commits

Author SHA1 Message Date
Avi Deitcher
403e8f9353
Merge pull request #3797 from deitch/use-images-from-cache
add support for building from cached images
2022-07-20 09:19:47 -04:00
Avi Deitcher
4e7f87e1ea
Merge pull request #3804 from giggsoff/allow-docker-multiarch
Allow store to docker multiarch builds
2022-07-18 19:08:26 +03:00
David Scott
8070434cad
Merge pull request #3542 from thaJeztah/configurable_socket
pkg/trim-after-delete: make docker socket path configurable
2022-07-17 03:26:52 -07:00
David Scott
a3327ef377
Merge pull request #3794 from giggsoff/net-admin-sysctl
Add CAP_NET_ADMIN capability to sysctl
2022-07-17 03:25:19 -07:00
Petr Fedchenkov
39f1649995
Allow store to docker multiarch builds
We do not allow to load into docker images that are targets another
platform differ from current arch. Assume this is because of no support
of manifest. But we can keep all images in place by adding arch suffix
and using tag without arch suffix to point onto current system arch. It
will help to use images from docker for another arch.

Signed-off-by: Petr Fedchenkov <giggsoff@gmail.com>
2022-07-15 16:51:18 +03:00
Avi Deitcher
a90ff542cd add support for building from cached images
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-07-14 12:53:34 +03:00
Avi Deitcher
44dfac2725
Merge pull request #3801 from waldner/master
New output format: iso-efi-initrd
2022-07-12 12:03:11 +03:00
Davide Brini
860934d5d9 New output format: iso-efi-initrd
This option was previously not available and required postprocessing of a `tar-kernel-initrd` output.

Comparison with `iso-efi`:

`iso-efi` only loads the kernel at boot, and the root filesystem is mounted from the actual boot media (eg, a CD-ROM - physical or emulated). This can often cause trouble (it has for us) for multiple reasons:
- the linuxkit kernel might not have the correct drivers built-in for the hardware (see #3154)
- especially with virtual or emulated CD-ROMs, performance can be abysmal: we saw the case where the server IPMI allowed using a ISO stored in AWS S3 over HTTP...you can imagine what happens when you start doing random I/O on the root fs in that case.
- The ISO image has the root device name baked in (ie, `/dev/sr0`) which fails if for some reason the CD-ROM we're running from doesn't end up using that device, so manual tweaking is required (see #2375)

`iso-efi-initrd`, on the other hand, packs the root filesystem as an initramfs (ie similar to what the raw output does, except that in this case we're preparing an ISO image), so both the kernel and the initramfs are loaded in memory by the boot loader and, once running, we don't need to worry about root devices or kernel drivers (and the speed is good, as everything runs in RAM).

Also, the generated ISO can be copied verbatim (eg with `dd`) onto a USB media and it still works.

Finally, the image size is much smaller compared to `iso-efi`.

IMHO, `iso-efi-initrd` could be used almost anywhere `iso-efi` would be used, or might even supersede it. I can't think of a scenario where one might explicitly want to use `iso-efi`.

Points to consider:

- Not tested under aarch64 as I don't have access to that arch. If the automated CI tests also test that, then it should be fine.
- I'm not sure what to put inside `images.yaml` for the `iso-efi-initrd` image. As it is it works of course (my personal image on docker hub), but I guess it'll have to be some more "official" image. However, that cannot be until this PR is merged, so it's kind of a chicken and egg situation. Please advise.
- I can look into adding the corresponding `iso-bios-initrd` builder if there is interest.

![cute seal](https://sites.psu.edu/siowfa16/files/2016/09/baby-seal-29vsgyf-288x300.jpg)

Signed-off-by: Davide Brini <waldner@katamail.com>
2022-07-11 20:26:14 +02:00
Avi Deitcher
ad3d8bdac0
Merge pull request #3800 from waldner/master
Fix: #3799 golint requires comments on non-main package for blank import
2022-07-10 17:58:49 +03:00
Davide Brini
9edeba42d7 Fix: #3799 golint requires comments on non-main package for blank import
Signed-off-by: Davide Brini <waldner@katamail.com>
2022-07-10 11:55:51 +02:00
Rolf Neugebauer
806c5c418d
Merge pull request #3796 from deitch/document-cache
add docs to the cache spec
2022-07-06 10:10:10 +01:00
Avi Deitcher
9c95286a35 add docs to the cache spec
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-07-01 15:30:22 +03:00
Avi Deitcher
7778f34c0c
Merge pull request #3791 from deitch/direct-buildkit
build directly with buildkit
2022-07-01 12:29:20 +03:00
Petr Fedchenkov
afefea9740
Add CAP_NET_ADMIN capability to sysctl
With linux kernel 5.15+ change of proc/sys/net/ipv4/ip_forward require
CAP_NET_ADMIN (https://github.com/torvalds/linux/commit/8292d7f6). We do
 not use ip_forward now, but we should be ready for future changes of
 conf files.

Signed-off-by: Petr Fedchenkov <giggsoff@gmail.com>
2022-06-28 16:55:32 +03:00
Avi Deitcher
0929aabe50 build directly with buildkit
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-06-28 10:36:30 +03:00
Avi Deitcher
fb111d3bbf add buildkit module and update packages and vendor
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-06-28 10:35:45 +03:00
Avi Deitcher
1073b2dd8d
Merge pull request #3790 from giggsoff/support-gcp-vtpm
Support for vTPM on GCP
2022-06-21 18:43:09 +02:00
Petr Fedchenkov
a51f40f68b
Support for vTPM on GCP
Add options to support vTPM-enabled VMs on GCP

Signed-off-by: Petr Fedchenkov <giggsoff@gmail.com>
2022-06-21 16:53:41 +03:00
Avi Deitcher
74b8215f0c
Merge pull request #3788 from deitch/pkg-dummy
test pkg/dummy
2022-06-08 09:29:22 +03:00
Avi Deitcher
58486bbe88 remove silent from Makefile so we can see what command it is doing; sort dirs for consistency
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-06-07 21:16:13 +03:00
Avi Deitcher
857f53cdff test pkg/dummy
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-06-07 21:16:13 +03:00
Avi Deitcher
0cb96dcfa0
Merge pull request #3789 from deitch/continue-after-noarchs
when no archs for pkg to build, should continue rather than return
2022-06-07 21:12:34 +03:00
Avi Deitcher
9218f2577d when no archs for pkg to build, should continue rather than return, or it misses other packages
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-06-07 19:45:35 +03:00
Avi Deitcher
b56a0df58d
Merge pull request #3787 from deitch/skip-build-if-no-platforms 2022-06-07 13:24:59 +03:00
Avi Deitcher
02fd6c48ee do not push if the tag and digest are identical
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-06-07 10:45:29 +03:00
Avi Deitcher
6cd8a874a6 do not try to build or push if no architectures are available
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-06-07 10:25:41 +03:00
Avi Deitcher
a8c4b174a3
Merge pull request #3785 from deitch/login-docker-hub
login to docker hub before publishing
2022-06-06 21:26:38 +03:00
Rolf Neugebauer
b33bda7a33
Merge pull request #3722 from gabchab/openssl-in-kernel-build
Add openssl to the kernel-build
2022-06-03 21:55:47 +01:00
Rolf Neugebauer
9e333a1358
Merge pull request #3775 from deitch/doc-kernel-builder
add docs about how to find the builder
2022-06-03 20:48:20 +01:00
Avi Deitcher
9c673d5650 login to docker hub before publishing
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-05-29 14:52:21 -07:00
Avi Deitcher
04aaebfa71
Merge pull request #3784 from deitch/download-linuxkit-in-dir
ensure bin/ dir exists, parametrize linuxkit filename
2022-05-29 11:56:45 -07:00
Avi Deitcher
a848205f9d ensure bin/ dir exists, parametrize linuxkit filename
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-05-29 10:27:55 -07:00
Avi Deitcher
e57122d0ef
Merge pull request #3783 from deitch/properly-download-linuxkit 2022-05-29 07:11:15 -07:00
Avi Deitcher
830ac050c6 download artifact from other workflow
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-05-25 09:56:08 -10:00
Avi Deitcher
c972168d02
Merge pull request #3781 from deitch/pr-without-push
remove need for maintainers to build packages
2022-05-25 08:05:11 -10:00
David Scott
563060731e
Merge pull request #3768 from fredericdalleau/kernel-udpate-220309
update 5.10 and 5.15 kernels to 5.10.104 resp 5.15.27
2022-05-25 14:19:19 +01:00
Frédéric Dalleau
d308349f96 ./scripts/update-component-sha.sh --hash 5.15.15 5.15.27 2022-05-25 13:39:10 +02:00
Frédéric Dalleau
0d8a1e3033 script/update-component-sha.sh --hash 5.10.92 5.10.104
Signed-off-by: Frédéric Dalleau <frederic.dalleau@docker.com>
2022-05-25 13:39:10 +02:00
Frédéric Dalleau
4ec8ef8784 Update amd64 kernel config to 5.10.104
Signed-off-by: Frédéric Dalleau <frederic.dalleau@docker.com>
2022-05-25 13:39:09 +02:00
Frédéric Dalleau
71c04547b2 Update arm64 kernel config to 5.10.104
Signed-off-by: Frédéric Dalleau <frederic.dalleau@docker.com>
2022-05-25 13:39:09 +02:00
Frédéric Dalleau
2028ed927d Update kernel version to 5.10.104
Signed-off-by: Frédéric Dalleau <frederic.dalleau@docker.com>
2022-05-25 13:39:09 +02:00
Frédéric Dalleau
7e79fd449a Update amd64 kernel config to 5.15.27
Signed-off-by: Frédéric Dalleau <frederic.dalleau@docker.com>
2022-05-25 13:39:09 +02:00
Frédéric Dalleau
420a08c709 Update arm64 kernel config to 5.15.27
Signed-off-by: Frédéric Dalleau <frederic.dalleau@docker.com>
2022-05-25 13:39:09 +02:00
Frédéric Dalleau
2e62dd078c Update kernel version to 5.15.27
Signed-off-by: Frédéric Dalleau <frederic.dalleau@docker.com>
2022-05-25 13:39:09 +02:00
Avi Deitcher
cd5cea8c02 remove need for maintainers to build packages
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-05-23 20:24:07 -10:00
Neil Gerring
33d86ddebe
Fix a merge conflict in openstack.yml example
Signed-off-by: Neil Gerring <ng@neilgerring.co.uk>
2022-05-13 14:13:06 +01:00
Avi Deitcher
3351eee596 add docs about how to find the builder
Signed-off-by: Avi Deitcher <avi@deitcher.net>
2022-04-24 17:44:24 +03:00
Avi Deitcher
b710224cdf
Merge pull request #3774 from zededa-yuri/build-arg
Declare build-args in build.yml
2022-04-15 12:38:37 +03:00
Yuri Volchkov
1a013f4424 Declare build-args in build.yml
This allows multiple build flavors for a single codebase, without
sacrificing reproducible builds. The build-args are set in build.yml,
which is typically under the source control (if it is not, then no
reproducible builds are possible anyways). Meaning that mutating
build-args would result in setting "dirty" flag.

Intended use of this commit is to switch between build flavors by
specifying a different yaml file (presumably also under the version
control)  by  `-build-yml` option.

Because it is impossible to build a final image from packages in
cache, the test for this feature relies on the `RUN echo $build-arg`
output during the `pkg build` process.

Signed-off-by: Yuri Volchkov <yuri@zededa.com>
2022-04-13 17:36:55 +00:00
Avi Deitcher
e3bedd0985
Merge pull request #3772 from deitch/runc-1.1 2022-03-23 06:51:00 -07:00