Derek Nola
3fcbac8d26
assign GOCOVERDIR in docker tests
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-27 11:30:42 -08:00
Derek Nola
031c11d369
Convert snapshotrestore from E2E to Docker test
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-27 11:30:42 -08:00
Derek Nola
57361c9ae3
DRY Docker test configuration strucutres - Reduce TestConfig fields, rename secret -> token - remove unused ENV control vars - Consolidate DeployWorkload function similar to E2E function
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-27 11:30:42 -08:00
Derek Nola
7392806b7f
Make (Docker) RunOnNode a method
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-27 11:30:42 -08:00
Derek Nola
669c11a686
Replace docker go test SERVER_ARGS env with config.yaml injection
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
x
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-27 11:30:42 -08:00
Derek Nola
ca165cacbc
Add support for restarting k3s docker nodes
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-27 11:30:42 -08:00
Vitor Savian
7e18c69254
Add auto import images for containerd image store
...
* Add auto import images
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
* Fix EOF error log when importing tarball files
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
* Delaying queue
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
* Add parse for images
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
2025-01-09 13:15:27 -03:00
Brad Davidson
f345697c0a
Add tests for supervisor request handlers
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2025-01-09 00:51:19 -08:00
Brad Davidson
e6327652f0
Replace *core.Factory with CoreFactory interface
...
Make this field an interface instead of pointer to allow mocking. Not sure why wrangler has a type that returns an interface instead of just making it an interface itself. Wrangler in general is hard to mock for testing.
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2025-01-09 00:51:19 -08:00
Brad Davidson
c20c06373a
Move additional core/v1 mocks into tests package
...
Convert nodepassword tests to use shared mocks
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2025-01-09 00:51:19 -08:00
Brad Davidson
8f8cfb56b5
Move core/v1 mock into tests package for reuse
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2025-01-09 00:51:19 -08:00
Brad Davidson
f8271d8506
Add test for join existing cluster
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2025-01-09 00:51:19 -08:00
Derek Nola
67ffd2ab1e
Fix skew semver for release-XX branches ( #11531 )
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-07 12:25:42 -08:00
Derek Nola
c3460fce73
Add "k3s certificate check" clause for better test coverage ( #11485 )
...
* Add "k3s certificate check" clause for better test coverage
Signed-off-by: Derek Nola <derek.nola@suse.com >
* Add table support to cert check
Signed-off-by: Derek Nola <derek.nola@suse.com >
---------
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-07 10:19:23 -08:00
Derek Nola
2f432a1cde
Upload E2E logs on failure as GHA artifacts ( #11514 )
...
* Upload E2E journald logs as artifacts in GHA
Signed-off-by: Derek Nola <derek.nola@suse.com >
* Improve fork information for parent extraction
Signed-off-by: Derek Nola <derek.nola@suse.com >
---------
Signed-off-by: Derek Nola <derek.nola@suse.com >
2025-01-07 09:50:39 -08:00
Brad Davidson
68fbd1a6b5
Fix snapshot flake
...
Avoid "snapshot save already in progress" flake when snapshot reconcile from previous save is still in progress.
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-20 14:41:40 -08:00
Brad Davidson
f83cce95cf
Add test for kubelet config-dir
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-20 14:41:40 -08:00
Brad Davidson
93e548326a
Improve error handling of CheckDeployments test helper
...
Expose actual error, so that we can tell if the deployment is not found or not ready/available
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-20 14:41:40 -08:00
Hussein Galal
763188d642
V1.32.0+k3s1 ( #11478 )
...
* Update libraries and codegen for k8s 1.32
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
* Fixes for 1.32
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
* Disable tests with down-rev agents
These are broken by AuthorizeNodeWithSelectors being on by default. All
agents must be upgraded to v1.32 or newer to work properly, until we
backport RBAC changes to older branches.
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
---------
Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com >
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
Co-authored-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-20 23:17:14 +02:00
Brad Davidson
e143e0fa12
Add hidden flag/var for supervisor/apiserver listen config
...
Add flags supervisor and apiserver ports and bind address so that we can add an e2e to cover supervisor and apiserver on separate ports, as used by rke2
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-10 09:31:18 -08:00
Brad Davidson
e9cf3a7ab5
Tail journald logs into report on suite failure
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-06 11:45:34 -08:00
Brad Davidson
45195e2654
Fix integration test failure message
...
The error message should be printf style, not just concatenated. The
current message is garbled if the command or result contains things that
look like formatting directives:
`Internal error occurred: error sending request: Post "https://10.10.10.102:10250/exec/default/volume-test/volume-test?command=sh&command=-c&command=echo+local-path-test+%!!(MISSING)E(MISSING)+%!!(MISSING)F(MISSING)data%!!(MISSING)F(MISSING)test&error=1&output=1 ": proxy error from 127.0.0.1:6443 while dialing 10.10.10.102:10250, code 502: 502 Bad Gateway`
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-06 11:45:34 -08:00
Brad Davidson
81dda9d626
Add command output to test failure message
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-06 11:45:34 -08:00
Derek Nola
183f0c8d09
Fix secrets-encrypt reencrypt timeout error ( #11385 )
...
* Add missing default OS for split server test
Signed-off-by: Derek Nola <derek.nola@suse.com >
* Launch go routine and return for k3s secrets-encrypt reencrypt
Signed-off-by: Derek Nola <derek.nola@suse.com >
---------
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-12-05 09:11:22 -08:00
Derek Nola
7296fa8863
Fix leap install test ( #11379 )
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-12-03 17:19:21 -08:00
Brad Davidson
5bb3d82e27
Add rewrite test to privateregistry e2e
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-12-03 11:58:51 -08:00
manuelbuil
4ec261733e
If no etcd was deployed, fail etcd-snapshot with a useful error
...
Signed-off-by: manuelbuil <mbuil@suse.com >
2024-11-28 09:40:42 +01:00
Derek Nola
c669600c8f
Fix Branch Name logic for Dependabot and UpdateCLI pushes to k3s-io ( #11376 )
...
* Improve node checking for etcd docker test
* Fix branch name for dependabot and updatecli PRs
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-11-27 09:50:14 -08:00
Derek Nola
b5e2fa77a6
Convert legacy docker tests from bash to golang ( #11357 )
...
* Convert the following Docker test from Bash to Go
- basics
- bootstraptoken
- cacerts
- compat -> skew
- etcd
- lazypull
- upgrade
Signed-off-by: Derek Nola <derek.nola@suse.com >
* Add Docker go tests to GHA
* Prebuild K3s Go Tests
* Strip go test binaries to reduce size
* Handle complex branch options
Signed-off-by: Derek Nola <derek.nola@suse.com >
* Implement basic golang tests on arm and arm64 pipelines
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-11-26 12:30:52 -08:00
Vitor Savian
9bd48b1a3f
Add ubuntu 24.04 apt command for e2e test
...
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
2024-11-26 11:45:04 -03:00
Emmanuel Ferdman
59707dab3d
Update localstorage_int_test.go reference ( #11339 )
...
Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com >
2024-11-19 10:35:31 -08:00
Derek Nola
c3eece6071
Fix GenKubeConfigFile, move from "cat" command to "scp"
...
Remove CI fog warnings from RunCmdOnNode output
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-11-12 15:54:37 -08:00
Brad Davidson
a39e191906
Add tests for ETCD.Test()
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-10-30 12:18:48 -07:00
Derek Nola
9be40761d7
Reduce the number of GH api request for E2E nightly ( #11148 )
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-10-23 09:36:06 -07:00
Derek Nola
c0d661b334
Check the last 10 commits for upgrade E2E test ( #11086 )
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-10-16 12:22:38 -07:00
manuelbuil
e475ba70b8
Add e2e test for advanced fields in services
...
Signed-off-by: manuelbuil <mbuil@suse.com >
2024-10-09 12:32:27 +02:00
Brad Davidson
b1a42e5d43
Add ca-cert rotation integration test
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-10-08 17:03:31 -07:00
Robert Silén
40eda6a823
Add MariaDB to E2E ( #10724 )
...
* add mariadb to Validate and Upgrade E2E tests
Signed-off-by: robertsilen <robert.silen@iki.fi >
Signed-off-by: Robert Silén <robert.silen@iki.fi >
Co-authored-by: Derek Nola <derek.nola@suse.com >
2024-09-19 08:40:02 -07:00
Manuel Buil
483d76b34a
Add int test for flannel-ipv6masq
...
Signed-off-by: Manuel Buil <mbuil@suse.com >
2024-09-17 12:00:33 +02:00
Derek Nola
36282dc39b
Launch private registry with init so the container can be killed on cleanup ( #10822 )
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-09-04 16:22:24 -07:00
Derek Nola
fc2eb49e38
Fix deploy latest commit on E2E tests ( #10725 )
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-08-26 08:22:42 -07:00
Derek Nola
38df76708d
Fix caching name for e2e vagrant box ( #10695 )
...
Signed-off-by: Derek Nola <derek.nola@suse.com >
2024-08-13 09:22:56 -07:00
Derek Nola
ac247d29cf
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-08-12 09:26:19 -07:00
Vitor Savian
3aceb85c22
Add a change for killall to not unmount server and agent directory
...
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
Add recursive search and deletion of unmounted/mounted dirs in killall
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
Only clean the server and agent directory if it is uninstall
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
Add uninstall test to check mount points
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
Add uninstall test in CI
Signed-off-by: Vitor Savian <vitor.savian@suse.com >
2024-08-07 10:06:12 -07:00
Derek Nola
ecff337e00
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-07-25 09:37:03 -07:00
Brad Davidson
c36db53e54
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 >
2024-07-10 13:13:55 -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
Brad Davidson
f9130d537d
Fix embedded mirror blocked by SAR RBAC and re-enable test
...
Signed-off-by: Brad Davidson <brad.davidson@rancher.com >
2024-05-31 08:33:18 -07:00
dependabot[bot]
4cb4542c3a
Bump ubuntu from 22.04 to 24.04 in /tests/e2e/scripts
...
Bumps ubuntu from 22.04 to 24.04.
---
updated-dependencies:
- dependency-name: ubuntu
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com >
2024-05-28 20:12:14 -07:00
Manuel Buil
3f62ec3207
Add extra log in e2e tests
...
Signed-off-by: Manuel Buil <mbuil@suse.com >
2024-05-27 16:11:12 +02:00