1735 Commits

Author SHA1 Message Date
Andrey Smirnov
390137447f
feat: enable KubePrism by default
Fixes #7787

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-25 23:12:33 +04:00
Andrey Smirnov
a52d3cda3b
chore: update gen and COSI runtime
No actual changes, adapting to use new APIs.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-22 12:13:13 +04:00
Noel Georgi
29b201d619
feat: enable common h/w sensors
Enable common h/w sensor modules.

Ref: https://github.com/siderolabs/pkgs/pull/815

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-09-22 00:15:53 +05:30
Andrey Smirnov
5ca4d58dc9
fix: generate of modules.dep when on the machine
When running on the machine, the extensionTreePath is not writeable, so
create and clean up a temporary directory to host `modules.dep`
extension.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-20 15:51:22 +04:00
Noel Georgi
5efcccb6b1
chore: bump kernel to 6.1.54
Bump kernel to 6.1.54.

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-09-20 16:06:41 +05:30
Andrey Smirnov
f3a370acb2
feat: update Flannel to 0.22.3
See https://github.com/flannel-io/flannel/releases/tag/v0.22.3

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-18 23:05:18 +04:00
Andrey Smirnov
efdee69658
feat: update Kubernetes to 1.28.2
See https://github.com/kubernetes/kubernetes/releases/tag/v1.28.2

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-18 22:32:32 +04:00
Andrey Smirnov
e3b4940588
fix: build CPU ucode correctly for early loader
Closes #7729

This follows the steps described in
https://www.kernel.org/doc/html/v6.1/x86/microcode.html#early-load-microcode

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-18 14:03:41 +04:00
Andrey Smirnov
c5bd0ac5cf
refactor: reimplement the depmod extension rebuilder
Drop loop device/mounts completely, use userspace utilities to extract
and lay over module trees in the tmpfs.

Discover kernel version automatically instead of hardcoding it to be
current one (required for Image Service).

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-15 21:51:42 +04:00
Noel Georgi
3ef670a9e8
chore: pull in dm modules
Pull in dm-modules.

Ref: https://github.com/siderolabs/pkgs/pull/791

Diff:

```bash
❯ diff -r --color _out/kernel-a/lib/modules/6.1.51-talos/modules.dep _out/kernel-b/lib/modules/6.1.51-talos/modules.dep
100a101
> kernel/drivers/md/dm-bio-prison.ko:
102a104
> kernel/drivers/md/persistent-data/dm-persistent-data.ko:
103a106
> kernel/drivers/md/dm-thin-pool.ko: kernel/drivers/md/persistent-data/dm-persistent-data.ko kernel/drivers/md/dm-bio-prison.ko
```

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-09-15 15:16:02 +02:00
Andrey Smirnov
87c1b3ddd8
fix: calculate UKI ISO size dynamically
Fixes #7712

Instead of hardcoding a size, calculate the UKI and sd-boot size. UKI
has dynamic size, as it depends on number of system extensions
installed.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-15 14:20:38 +04:00
Andrey Smirnov
a096f05a56
chore: update gRPC library and enable shared write buffers
Fixes #7576

See https://github.com/grpc/grpc-go/pull/6309

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-13 21:27:46 +04:00
Artem Chernyshev
2960f93baa
feat: add readonly information to the disks API response
Forward device readonly info from `go-blockdevice` library.

Signed-off-by: Artem Chernyshev <artem.chernyshev@talos-systems.com>
2023-09-12 18:09:59 +03:00
Andrey Smirnov
735bf9ed08
feat: bring in Google vNIC driver
See https://github.com/siderolabs/pkgs/pull/802

The module is included by default, but loaded on demand.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-12 16:26:45 +04:00
Serge Logvinov
3f52320752
feat: upgrade-k8s without comments
This feature allows us to remove any comments from the machineconfig after
upgrading Kubernetes.

Signed-off-by: Serge Logvinov <serge.logvinov@sinextra.dev>
Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-12 14:50:56 +04:00
Andrey Smirnov
da73b563dd
chore: update Go to 1.21.1
See https://go.dev/doc/devel/release#go1.21.minor

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-07 14:31:40 +04:00
Andrey Smirnov
5e11f08a63
fix: trim file path in the container image
When imager generates `installer` image, it should generate a layer
without `/` in front, e.g. `/usr/install` -> `usr/install`.

It works either way, but this seems to be cleaner.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-06 22:55:39 +04:00
Noel Georgi
3d2dad4e69
chore: show securtiystate on dashboard
Show Talos SecurityState and MountStatus on dashboard.

Fixes: #7675

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-09-06 21:46:25 +05:30
Noel Georgi
3fbed806c4
chore: add tests for util-linux extensions
Add tests for utils-linux extensions.

Ref: https://github.com/siderolabs/extensions/pull/216

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-09-05 19:29:50 +05:30
Andrey Smirnov
6058c36023
fix: shorten VLAN link names to fit into the limit of 15 characters
Fixes #7679

This should be no-op if the link name is <= 10 chars, but with
predictable interface names based on MAC addresses, they have to be
shortened to make some space for VLAN ID.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-05 14:51:09 +04:00
Andrey Smirnov
f7473e4778
feat: update default Kubernetes to 1.28.1
See https://github.com/kubernetes/kubernetes/releases/tag/v1.28.1

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-04 16:07:03 +04:00
Andrey Smirnov
c918c0855d
fix: set correct (1 year) talosconfig expiration
Fixes #7698

Also fix `talosctl config info` for `talosconfig` without a client
certificate (e.g. Omni-generated one).

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-04 14:46:28 +04:00
Andrey Smirnov
79bbdf454e
fix: set proper timeouts for KubePrism loadbalancer
The default timeouts are very aggressive, and we should use explicit
timeouts so that healh checks don't run that often.

Fixes #7690

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-09-01 00:16:09 +04:00
Andrey Smirnov
b8fb55d5c2
fix: use a mount prefix when installing a bootloader
This is not a problem in general, but when running multiple image
generation procedures using the same mount point is a problem.

This is a no-op if `MountPrefix` is not set (when installing/upgrading
vs. creating an image).

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-31 22:21:41 +04:00
Andrey Smirnov
44f59a8049
feat: improve imager APIs
* report the final output path of the asset
* allow 'cmdline' output (just to get the kernel cmdline, e.g. for PXE
  booting)
* support pre-pulled container images for extensions

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-31 20:52:58 +04:00
Andrey Smirnov
3c9f7a7de6
chore: re-enable nolintlint and typecheck linters
Drop startup/rand.go, as since Go 1.20 `rand.Seed` is done
automatically.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-25 01:05:41 +04:00
Andrey Smirnov
c51e2c9b48
feat: update CoreDNS to 1.11.1
See https://github.com/coredns/coredns/releases/tag/v1.11.1

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-24 21:32:06 +04:00
Andrey Smirnov
8670450d28
release(v1.6.0-alpha.0): prepare release
This is the official v1.6.0-alpha.0 release.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-24 17:09:34 +04:00
Noel Georgi
6778ded29d
feat: add e2e-aws for nvidia extensions
Add e2e tests for nvidia

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-08-24 17:43:36 +05:30
Andrey Smirnov
74c07ed714
chore: update Go to 1.21
This fixes a problem in the `RouteSpecController` which is due to a
subtle (but correct) change in the behavior in the `stdlib`.

Also some small (but should be safe) bumps.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-23 22:52:04 +04:00
Andrey Smirnov
a28d72e9c2
fix: ova contents to be named disk.*
It looks like while our code accepted any random name for the contents
of `.ova`, it should be named `disk.*`.

Change the code accordingly.

Fixes #7663

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-23 22:05:39 +04:00
Andrey Smirnov
9608ef56dc
chore: allow bridge traffic with DHCP broadcast traffic
This is required for https://github.com/siderolabs/sidero/pull/1070, as
we need to allow DHCP traffic from Sidero controller running in a VM
through the bridge to other VMs.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-23 18:37:37 +04:00
Noel Georgi
833895940b
chore: add tests for zfs extension
Add tests for ZFS and btrfs extensions.
Also fix the e2e-aws cron pipeline.

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-08-23 11:16:25 +05:30
Andrey Smirnov
92ad18c18f
fix: write correct capacity to the ovf
With the refactoring to 1.5, the confusion between bytes and megabytes
introduced this bug.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-17 18:54:28 +04:00
Noel Georgi
6b0373ebef
chore: move bash tests to integration
move extensions and secureboot tests to integration.
Makes it easier to test.

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-08-17 19:58:35 +05:30
Andrey Smirnov
97b4e3e91c
feat: update Kubernetes to 1.28.0
See https://github.com/kubernetes/kubernetes/releases/tag/v1.28.0

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-15 22:05:49 +04:00
Andrey Smirnov
bf3a5e0119
chore: add version compatibility for Talos 1.6
This will be backported to 1.5, so that Talos 1.5 machinery will still
provide compatibility for (future) Talos 1.6.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-11 16:09:08 +04:00
Andrey Smirnov
969e8097ce
feat: update Kubernetes to 1.28.0-rc.1
See https://github.com/kubernetes/kubernetes/releases/tag/v1.28.0-rc.1

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-11 15:39:58 +04:00
Andrey Smirnov
86c94eff8d
refactor: docgen and config examples
Short version is: move from global variables/`init()` function into
explicit functions.

`docgen` was updated to skip creating any top-level global variables,
now `Doc` information is generated on the fly when it is accessed.
Talos itself doesn't marshal the configuration often, so in general it
should never be accessed for Talos (but will be accessed e.g. for
`talosctl`).

Machine config examples were changed manually from variables to
functions returning a value and moved to a separate file.

There are no changes to the output of `talosctl gen config`.

There is a small change to the generated documentation, which I believe
is a correct one, as previously due to value reuse it was clobbered with
other data.

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-10 14:56:01 +04:00
Andrey Smirnov
e1b288679e
refactor: compile regex in validation method on the first use
See #7578

With this change and #7590, init allocation:

```
init github.com/siderolabs/talos/pkg/machinery/config/types/v1alpha1 @2.1 ms, 0.006 ms clock, 1408 bytes, 26 allocs
```

Previously, it was:

```
init github.com/siderolabs/talos/pkg/machinery/config/types/v1alpha1 @3.8 ms, 0.30 ms clock, 184248 bytes, 1176 allocs
```

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-09 19:32:12 +04:00
Andrey Smirnov
daa4c185ae
docs: add what's new and documentation for Talos 1.5
* SecureBoot
* TPM disk encryption
* KubePrism
* Boot Asset Generation

Signed-off-by: Andrey Smirnov <andrey.smirnov@siderolabs.com>
2023-08-09 15:48:50 +04:00
Dmitriy Matrenichev
c4a1ca8d61
chore: remove <-errCh where possible in grpc methods
Simplify code by passing error directly into the pipe closer.

Signed-off-by: Dmitriy Matrenichev <dmitry.matrenichev@siderolabs.com>
2023-08-07 22:28:58 +03:00
Andrey Smirnov
e0f383598e
chore: clean up the output of the imager
Use `Progress`, and options to pass around the way messages are written.

Fixed some tiny issues in the code, but otherwise no functional changes.

To make colored output work with `docker run`, switched back image
generation to use volume mount for output (old mode is still
functioning, but it's not the default, and it works when docker is not
running on the same host).

Signed-off-by: Andrey Smirnov <andrey.smirnov@talos-systems.com>
2023-08-07 16:00:14 +04:00
Andrey Smirnov
fb536af4d1
chore: optimize memory usage of tcell library on init
There are two changes here:

* build `machined` binary with `tcell_minimal` tag (which disables
  loading some parts of the terminfo database), which also affects
  `apid`, `trustd` and `dashboard` processes, as they run from the same
  executable; in `dashboard` explicitly import `linux` terminal we're
  using when the `dashboard` runs on the machine
* pass `TCELL_MINIMIZE=1` environment variable to each Talos process
  which removes 0.5MiB of runewdith allocation for a lookup table

See #7578

Signed-off-by: Andrey Smirnov <andrey.smirnov@talos-systems.com>
2023-08-04 17:59:18 +04:00
Artem Chernyshev
7d688ccfeb
fix: make encryption config provider default to luks2 if not set
Fixes: https://github.com/siderolabs/talos/issues/7515

Rename `Kind` to `Provider` in the `v1alpha1_provider`.

Signed-off-by: Artem Chernyshev <artem.chernyshev@talos-systems.com>
2023-08-04 12:20:55 +03:00
Dmitriy Matrenichev
80238a05a6
chore: unify semver under github.com/blang/semver/v4
Currently, we use `github.com/coreos/go-semver/semver` and `github.com/hashicorp/go-version`
for version parsing. As we use `github.com/blang/semver/v4` in our other projects, and it
has more features, it makes sense to use it across the projects. It also doesn't allocate
like crazy in `KubernetesVersion.SupportedWith`.

Signed-off-by: Dmitriy Matrenichev <dmitry.matrenichev@siderolabs.com>
2023-08-04 00:29:52 +03:00
Andrey Smirnov
0f1920bdda
chore: provide a resource to peek into Linux clock adjustments
This is a follow-up for #7567, which won't be backported to 1.5.

This allows to get an output like:

```
$ talosctl -n 172.20.0.5 get adjtimestatus -w
NODE         *   NAMESPACE TYPE            ID     VERSION   OFFSET        ESTERROR   MAXERROR   STATUS               SYNC
172.20.0.5   +   runtime   AdjtimeStatus   node   47        -18.14306ms   0s         191.5ms    STA_PLL | STA_NANO   true
172.20.0.5       runtime   AdjtimeStatus   node   48        -17.109555ms  0s         206.5ms    STA_NANO | STA_PLL   true
172.20.0.5       runtime   AdjtimeStatus   node   49        -16.134923ms  0s         221.5ms    STA_NANO | STA_PLL   true
172.20.0.5       runtime   AdjtimeStatus   node   50        -15.21581ms   0s         236.5ms    STA_PLL | STA_NANO   true
```

Signed-off-by: Andrey Smirnov <andrey.smirnov@talos-systems.com>
2023-08-03 22:06:53 +04:00
Andrey Smirnov
87fe8f1a2a
feat: implement image generation profiles
Support full configuration for image generation, including image
outputs, support most features (where applicable) for all image output
types, unify image generation process.

Signed-off-by: Andrey Smirnov <andrey.smirnov@talos-systems.com>
2023-08-02 19:13:44 +04:00
Andrey Smirnov
e685208ce5
chore: update go 1.20.7
Some final bumps for the go.mod before going beta.

Signed-off-by: Andrey Smirnov <andrey.smirnov@talos-systems.com>
2023-08-02 17:11:51 +04:00
Noel Georgi
5adeb5042f
feat: update extension spec allowlist for opengl
NVIDIA OpenGL/Vulkan files are super hard-coded.

Ref: https://github.com/siderolabs/extensions/pull/191

Fixes: https://github.com/siderolabs/extensions/issues/171

Signed-off-by: Noel Georgi <git@frezbo.dev>
2023-08-02 04:06:09 +05:30