Commit Graph

3388 Commits (6d4a3092eda1af55977d742973d5c4fccdf9f4c6)

Author SHA1 Message Date
Brad Davidson dd12197379 Fix /trivy action running against target branch instead of PR branch
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit 3d6e4a793a)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-09-06 11:30:23 -07:00
dependabot[bot] 925e95efe4 Bump aquasecurity/trivy-action from 0.20.0 to 0.24.0 (#10795)
Bumps [aquasecurity/trivy-action](https://github.com/aquasecurity/trivy-action) from 0.20.0 to 0.24.0.
- [Release notes](https://github.com/aquasecurity/trivy-action/releases)
- [Commits](https://github.com/aquasecurity/trivy-action/compare/0.20.0...0.24.0)

---
updated-dependencies:
- dependency-name: aquasecurity/trivy-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
(cherry picked from commit dacc636cf4)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-09-06 11:30:23 -07:00
Derek Nola 05dcd7f325 Add trivy scanning trigger for PRs (#10758)
Signed-off-by: Derek Nola <derek.nola@suse.com>
(cherry picked from commit fa6940d03d)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-09-06 11:30:23 -07:00
Roberto Bonafiglia ae5e25f531 Update CNI plugins version
Signed-off-by: Roberto Bonafiglia <roberto.bonafiglia@suse.com>
2024-09-04 16:47:21 -07:00
Derek Nola 01faf4ed39 Cover edge case when on new minor release for E2E upgrade test (#10781)
Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-09-04 11:50:40 -07:00
Derek Nola e562d883d6 Remove secrets encryption controller (#10612)
* Remove secrets encryption controller

Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-09-04 11:50:40 -07:00
Derek Nola 14e11631ca Fix secrets-encrypt metrics
Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-09-04 11:50:40 -07:00
Derek Nola 6f099943fc Fix caching name for e2e vagrant box (#10695)
Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-09-04 11:50:40 -07:00
Derek Nola 6f91699a69 Update to newer OS images for install testing (#10681)
* Update to newer OS images for install testing
* Update vagrant images used for E2E

Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-09-04 11:50:40 -07:00
Brooks Newberry 98262b5dee
Update to v1.30.4 (#10721) 2024-08-15 15:01:04 -07:00
Alireza Eskandari a125b7f623 Add tolerations support for DaemonSet pods
Signed-off-by: Alireza Eskandari <alireza.eskandari@wsd.com>
(cherry picked from commit 22fb7049bd)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-08-12 17:09:45 -07:00
Brad Davidson b11486d3cd
Bump containerd to v1.7.20 (#10660)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-08-06 08:52:01 -07:00
Derek Nola 6965b5d1a9 Allow Pprof and Superisor metrics in standalone mode (#10576)
* Allow pprof to run on server with `--disable-agent`
* Allow supervisor metrics to run on server with `--disable-agent`

Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-08-06 08:51:16 -07:00
Derek Nola cebd9dcc2d Use higher QPS for secrets reencryption (#10571)
* Use higher QPS for secrets reencryption

Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-08-06 08:51:16 -07:00
Derek Nola 60b2f5ab16 Enhance E2E Hardened option (#10558)
* Remove unnecessary hardened arguments

Signed-off-by: Derek Nola <derek.nola@suse.com>

* slim down hardened arguments

Signed-off-by: Derek Nola <derek.nola@suse.com>

---------

Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-08-06 08:51:16 -07:00
Brad Davidson 7190c74acc
[release-1.30] Backports for 2024-08 release cycle (#10664)
* Use pagination when retrieving etcd snapshot list

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit c2216a62ad)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

* Update secretsencrypt pagination

Make secretsencrypt page size and iteration consistent with other paginators

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit 891e72f90f)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

* Cap length of generated name used for servicelb daemonset

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit 21611c5665)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

* Fix ipv6 sysctl required by non-ipv6 LoadBalancer service

This is a partial revert of 095ecdb034,
with the workaround moved into klipper-lb.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit d4c3422a85)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

* remove deprecated use of wait functions

Signed-off-by: Will <will7989@hotmail.com>
(cherry picked from commit e4f3cc7b54)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

* Update pkg/secretsencrypt/config.go

Co-authored-by: Brad Davidson <brad@oatmail.org>
Signed-off-by: Will Andrews <will7989@hotmail.com>
(cherry picked from commit 3ec086f6f7)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

* Update pkg/cluster/managed.go

Co-authored-by: Derek Nola <derek.nola@suse.com>
Signed-off-by: Will Andrews <will7989@hotmail.com>
(cherry picked from commit e2179aa957)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

* Wire lasso metrics up to common gatherer

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit e168438d44)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

* Fix cloudprovider controller name

Looking at metrics revealed the cloudprovider controller name was anempty string.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit bffdf463e1)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>

---------

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
Signed-off-by: Will <will7989@hotmail.com>
Signed-off-by: Will Andrews <will7989@hotmail.com>
Co-authored-by: Will <will7989@hotmail.com>
Co-authored-by: Derek Nola <derek.nola@suse.com>
2024-08-05 09:35:00 -07:00
Brad Davidson fa4803843f bump docker/docker to v25.0.6
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-08-02 14:38:23 -07:00
Brad Davidson f646604010 Fix inconsistent loading of config dropins when config file does not exist
FindString would silently skip parsing dropins if the main config file
didn't exist. If a custom config file path was passed it would raise an
error, but if we were parsing the default config file and it didn't
exist it would just silently fail to load the dropins.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-29 16:59:57 -07:00
Brad Davidson ff06b107ed Add K3S_DATA_DIR as env var for --data-dir flag
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-29 16:59:57 -07:00
Brad Davidson b5dde94d75 Don't set K3S_DATA_DIR env var
This was only used to pass the bundled strongswan path through to the flannel ipsec backend, and is no longer needed. Ref: #719

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-29 16:59:57 -07:00
Brooks Newberry 086d9ca0fa
Update to v1.30.3-k3s1 and Go 1.22.5 (#10536)
Signed-off-by: Brooks Newberry <brooks@newberry.com>
2024-07-17 14:33:21 -07:00
Derek Nola 4323964859
[Release-1.30] July Test Backports (#10507)
* Move test-compat to GHA (#10414)

Signed-off-by: Derek Nola <derek.nola@suse.com>

* For E2E upgrade test, automatically determine the channel to use (#10461)

Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-07-15 10:45:29 -07:00
Brad Davidson 494d6df0cd Don't use server and token values from config file for etcd-snapshot commands
Fixes an issue where running etcd-snapshot commands on a node that has a server address set in the config will manage snapshots on that server, instead of on the local node as intended.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Brad Davidson 6cb63dd766 Add dial duration to debug error message
This should give us more detail on how long dials take before failing, so that we can perhaps better tune the retry loop in the future.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Brad Davidson 280aaa3a79 Fix IPv6 primary node-ip handling
I should have caught `[]string{cfg.NodeIP}[0]` and `[]string{envInfo.NodeIP.String()}[0]` in code review...

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Brad Davidson 97250ad656 Fix agents removing configured supervisor address
We shouldn't be replacing the configured server address on agents. Doing
so breaks the agent's ability to fall back to the fixed registration
endpoint when all servers are down, since we replaced it with the first
discovered apiserver address. The fixed registration endpoint will be
restored as default when the service is restarted, but this is not the
correct behavior. This should have only been done on etcd-only nodes
that start up using their local supervisor, but need to switch to a
control-plane node as soon as one is available.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Brad Davidson 4bf6fffe45 Fix reentrant rlock in loadbalancer.dialContext
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Brad Davidson 38a4f183bc Bump kine to v0.11.11
https://github.com/k3s-io/kine/compare/v0.11.9...v0.11.11
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Brad Davidson bcaa63929f Add etcd s3 config secret implementation
* Move snapshot structs and functions into pkg/etcd/snapshot
* Move s3 client code and functions into pkg/etcd/s3
* Refactor pkg/etcd to track snapshot and s3 moves
* Add support for reading s3 client config from secret
* Add minio client cache, since S3 client configuration can now be
  changed at runtime by modifying the secret, and don't want to have to
  create a new minio client every time we read config.
* Add tests for pkg/etcd/s3

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit c36db53e54)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
github-actions[bot] c338b31381 chore: Bump Trivy version
Made with ❤️️ by updatecli

(cherry picked from commit 5508589fae)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Brad Davidson b6ea5dd54f Ensure remotedialer kubelet connections use kubelet bind address
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit eb8bd15889)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
github-actions[bot] 7bfe84b3d4 chore: Bump golang:alpine version
Made with ❤️️ by updatecli

(cherry picked from commit 0b417385a4)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
github-actions[bot] 9bcad70a27 Bump Local Path Provisioner version (#10394)
* chore: Bump Local Path Provisioner version

Made with ❤️️ by updatecli

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
(cherry picked from commit a0b374508e)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
dependabot[bot] 729962d1ce Bump github.com/hashicorp/go-retryablehttp from 0.7.4 to 0.7.7
Bumps [github.com/hashicorp/go-retryablehttp](https://github.com/hashicorp/go-retryablehttp) from 0.7.4 to 0.7.7.
- [Changelog](https://github.com/hashicorp/go-retryablehttp/blob/main/CHANGELOG.md)
- [Commits](https://github.com/hashicorp/go-retryablehttp/compare/v0.7.4...v0.7.7)

---
updated-dependencies:
- dependency-name: github.com/hashicorp/go-retryablehttp
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit f6942f3de4)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Brad Davidson fc678dc27b Bump k3s-root to v0.14.0
Also remove the wg-add script that has been unused since v1.26 dropped the legacy wireguard backend

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
(cherry picked from commit 047664b610)
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-07-15 10:14:20 -07:00
Derek Nola 16321f2554
Set correct release channel for e2e upgrade test (#10460)
Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-07-09 09:00:04 -07:00
Brian Downs e9a5943900
update channel server for k3s2 (#10446) 2024-07-06 10:41:11 -07:00
Roberto Bonafiglia faeaf1b01b Update flannel to v0.25.4 and fixed issue with IPv6 mask
Signed-off-by: Roberto Bonafiglia <roberto.bonafiglia@suse.com>
2024-07-01 18:57:34 +02:00
Brooks Newberry a08ac6fcdc
update stable channel to v1.29.6+k3s1 (#10417)
Signed-off-by: Brooks Newberry <brooks@newberry.com>
2024-06-27 17:47:46 -07:00
Brad Davidson aa4794b372 Replace 1-weight semaphore on snapshots with simple mutex
Fixes an issue where the semaphore wasn't permanently initialized
until a scheduled snapshot was taken, allowing multiple on-demand
snapshots to be taken until the first scheduled snapshot was triggered.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-06-19 09:47:58 -07:00
Brad Davidson b4d4ed8f01 Fix agent supervisor port using apiserver port instead
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-06-13 15:13:21 -07:00
Brooks Newberry 9af17d2997
Update Kubernetes to v1.30.2 (#10349)
Signed-off-by: Brooks Newberry <brooks@newberry.com>
2024-06-13 09:09:52 -07:00
Harrison Affel f10cb29534 fix typo, use rancher/permissions
Signed-off-by: Harrison Affel <harrisonaffel@gmail.com>
2024-06-07 08:00:44 -07:00
Brad Davidson c0450a2cb4 Fix race condition panic in loadbalancer.nextServer
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-06-07 07:39:48 -07:00
Derek Nola cff6f7aa1d
Expand GHA go caching to includ newest release branch (#10307)
Signed-off-by: Derek Nola <derek.nola@suse.com>
2024-06-06 14:51:08 -07:00
Vitor Savian d9b8ba8d71
Add snapshot retention etcd-s3-folder fix
* Add snapshot retention folder fix

Signed-off-by: Vitor Savian <vitor.savian@suse.com>

* Add snapshot retention E2E test

Signed-off-by: Vitor Savian <vitor.savian@suse.com>

---------

Signed-off-by: Vitor Savian <vitor.savian@suse.com>
2024-06-06 17:31:01 -03:00
fmoral2 043b1eac5d
Add test for `isValidResolvConf` (#10302)
Signed-off-by: Francisco <francisco.moral@suse.com>
2024-06-06 17:02:31 -03:00
Brad Davidson df5db28a68
Add ADR for support for etcd s3 config secret (#9364)
* Add ADR for etcd s3 config secret
* Update ADR with changes from initial review

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-06-04 14:15:43 -07:00
Brad Davidson 1661f1024a Fix bug that caused agents to bypass local loadbalancer
If proxy.SetAPIServerPort was called multiple times, all calls after the
first one would cause the apiserver address to be set to the default
server address, bypassing the local load-balancer. This was most likely
to occur on RKE2, where the supervisor may be up for a period of time
before it is ready to manage node password secrets, causing the agent
to retry.

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2024-06-04 11:18:45 -07:00
Koen de Laat 79ba10f5ec fix: Use actual warningPeriod in certmonitor
Signed-off-by: Koen de Laat <koen.de.laat@philips.com>
2024-06-03 11:20:15 -07:00