Commit Graph

149 Commits

Author SHA1 Message Date
Hussein Galal
d55ec08675
Add el9 selinux rpm (#7443)
* Add el9 to the install script

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* Add rocky-9 install test to test el9 selinux

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* Add rocky-9 install test to test el9 selinux to workflow

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* Use el8 for fedora 37

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* Add a warning to reboot in coreos systems

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* remove k3s-selinux module in case of upgrade in el9

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* Check for available container-selinux and k3s-selinux

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* extend selinux upgrade to sle distros

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* create /var/lib/rpm-state in sle systems

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

* nit fix

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>

---------

Signed-off-by: galal-hussein <hussein.galal.ahmed.11@gmail.com>
2023-05-25 02:52:07 +03:00
Manuel Buil
290f67c939 Add '-all' flag to apply to inactive units
Signed-off-by: Manuel Buil <mbuil@suse.com>
2023-05-17 12:24:23 +02:00
Esteban Esquivel Alvarado
9bcfac8b88
Add Rotation certification Check (#7097)
* Add Certification Test to Validate Cluster

Signed-off-by: est-suse <esteban.esquivel@suse.com>

* Fix to stop/start for k3s certificate rotation

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

---------

Signed-off-by: est-suse <esteban.esquivel@suse.com>
Signed-off-by: Derek Nola <derek.nola@suse.com>
Co-authored-by: est-suse <esteban.esquivel@suse.com>
Co-authored-by: Derek Nola <derek.nola@suse.com>
2023-05-12 10:36:41 -07:00
Derek Nola
c6dc789e25
Add support for -cover + integration test code coverage (#7415)
* Add support for -cover in k3s server
* Update codecov reporting
* Sigterm in StopK3sServer
Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-05-08 12:46:51 -07:00
Ian Cardoso
3982213f06
add kube-* server flags integration tests (#7416)
This commit adds SearchK3sLog function to find specific strings in integration tests log file and also removes FindStringInCmdAsync function since it was not being used.

Signed-off-by: Ian Cardoso <osodracnai@gmail.com>
2023-05-08 05:25:47 -03:00
Brad Davidson
c98137ddca Fix token startup test
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2023-05-05 15:52:12 -07:00
Brad Davidson
cf9ebb3259 Fail to validate server tokens that use bootstrap id/secret format
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2023-05-05 12:24:35 -07:00
Derek Nola
7175ebe2be
E2E: Startup test cleanup + RunCommand Enhancement (#7388)
* Add beforesuite to startup
* Reduce timeouts for startup
* Fix cleanup + set kubeconfig

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-05-05 11:00:47 -07:00
Boleyn Su
a736b4b1b9
local-storage: Fix permission (#7217)
* local-storage: Fix permission

/var/lib/rancher/k3s/storage/ should be 700
/var/lib/rancher/k3s/storage/* should be 777

Fixes #2348

Signed-off-by: Boleyn Su <boleyn.su@gmail.com>

* Fix pod command field type

* Fix to int test

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

---------

Signed-off-by: Boleyn Su <boleyn.su@gmail.com>
Signed-off-by: Derek Nola <derek.nola@suse.com>
Co-authored-by: Brad Davidson <brad@oatmail.org>
Co-authored-by: Derek Nola <derek.nola@suse.com>
2023-05-04 10:43:54 -07:00
Brad Davidson
1ca035accc Add e2e test for --disable-agent
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2023-04-28 11:24:34 -07:00
Brooks Newberry
bbda54b332
Add longhorn storage test (#6445)
Signed-off-by: Brooks Newberry <brooks@newberry.com>
2023-04-28 11:17:19 -07:00
Ian Cardoso
1ac03aad43
Add integration tests for etc-snapshot server flags and refactor /tests/integration/integration.go/K3sStartServer (#7300)
This adds integration tests for the following flags: "--etcd-snapshot-name","--etcd-snapshot-dir","--etcd-snapshot-retention","--etcd-snapshot-schedule-cron" and "--etcd-snapshot-compress". It also refactors K3sStartServer to stop applying strings.Fields() into inputArgs, so it can accept arguments that have space in their definition.

Signed-off-by: Ian Cardoso <osodracnai@gmail.com>
2023-04-28 14:07:11 -03:00
Derek Nola
f2bde63eea
Kubernetes v1.27.1 (#7271)
* Bump go version to 1.20.3 to match upstream
* Bump cri-dockerd
* Bump golanci-lint
* go generate
* Bump selinux in cgroup test
* Bump to v1.27.1 tags
* Release documentation improvements
* Only run upgrade e2e test on PR

Signed-off-by: Derek Nola <derek.nola@suse.com>
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
Co-authored-by: Brad Davidson <brad.davidson@rancher.com>
2023-04-18 21:48:36 -07:00
fmoral2
6c394abb32
Add make commands to terraform automation and fix external dbs related issue (#7159)
* test: add make commands and dependencies

Signed-off-by: Francisco <francisco.moral@suse.com>

* fix: fix issue on logic for using external dbs and dependencies

Signed-off-by: Francisco <francisco.moral@suse.com>

---------

Signed-off-by: Francisco <francisco.moral@suse.com>
2023-04-06 12:17:13 -03:00
Derek Nola
d2e04b826a
Don't apply hardened args to agent (#7089)
Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-04-04 09:35:28 -07:00
ShylajaDevadiga
8ec7d5e6b0
fix_get_sha_url (#7187)
Signed-off-by: ShylajaDevadiga <shylaja@rancher.com>
2023-03-31 13:26:29 -07:00
Derek Nola
9980504196
Fix to Rotate CA e2e test (#7101)
* Include note on service keys

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

* Fix rotate cert ca test

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

* Remove periods

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

* Add new test to nightly script

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

---------

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-03-16 17:56:17 -07:00
Esteban Esquivel Alvarado
85b261096c
Add automation for Restart command for K3s (#7002)
Signed-off-by: est-suse <esteban.esquivel@suse.com>
2023-03-14 15:47:18 -07:00
Roberto Bonafiglia
7d2f997b3e Added multiClusterCIDR E2E test
Signed-off-by: Roberto Bonafiglia <roberto.bonafiglia@suse.com>
2023-03-14 18:30:52 +01:00
Roberto Bonafiglia
262cd7de0a Added IPv6 check and agent restart on e2e test utils
Signed-off-by: Roberto Bonafiglia <roberto.bonafiglia@suse.com>
2023-03-14 18:30:52 +01:00
Derek Nola
c259403af1
Bump various dependencies for CVEs (#7044)
* Bump wrangler to 1.1.1
* Match golang.org/x/net with flannel version
* Match golang.org/x/sys with containerd version
* Update gax-go to 2.1.1
* Isolate terraform e2e test with seperate go.mod/go.sum
* Bump containerd

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-03-13 09:37:45 -07:00
Derek Nola
522ad1e697
Add E2E to Drone (#6890)
* Initial drone vagrant pipeline

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

* Build e2e test image

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

* Add docker registry to E2E pipeline

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

* Bump libvirt image

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

* Add ci flag to secretsencryption

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

* Fix vagrant log on secretsencryption

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

* Remove DB parallel tests

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

* Reduce sonobuoy tests even further

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

* Add local build

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

* Add cron conformance pipeline

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

* Add string output for nodes

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

* Switch snapshot restore for upgrade cluster

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

* Fix cp

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

---------

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-03-10 19:53:41 -08:00
Derek Nola
9efa0797b7
Don't default to local K3s for startup test (#6950)
Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-02-13 15:00:57 -08:00
Brad Davidson
3d146d2f1b Allow for multiple sets of leader-elected controllers
Addresses an issue where etcd controllers did not run on etcd-only nodes

Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2023-02-10 10:46:48 -08:00
Brad Davidson
be7f751863 Add e2e tests for CA cert rotation
Signed-off-by: Brad Davidson <brad.davidson@rancher.com>
2023-02-06 15:09:31 -08:00
Derek Nola
7cad3db251
E2E: Consoldiate docker and prefer bundled tests into new startup test (#6851)
* Convert docker E2E to startup E2E
* Move preferedbundled into the e2e startup test

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-02-06 10:39:46 -08:00
Derek Nola
750cff561d
Bump vagrant boxes to fedora37 (#6832)
* Bump to generic/fedora37
* fix epic permissions
* Disable sonobuoy on rootless

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-01-30 13:14:29 -08:00
Derek Nola
86e36225f5
Consolidate E2E tests and GH Actions (#6772)
* Consolidate cluster reset and snapshot E2E tests
* Add more context to secrets-encryption test
* Reuse build workflow
* Convert updatecli to job level permissions
* Remove dweomer microos from E2E and install testing

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-01-27 09:01:13 -08:00
Derek Nola
75f77ab951
E2E Rancher and Hardened script improvements (#6778)
* Improve test-pad rancher script

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

* Improve hardened script and added kube-bench utility script

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

* Apply same audits for 1.22 and older

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

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-01-26 18:17:33 -08:00
ShylajaDevadiga
2007cdd54f
generate report and upload test results (#6737)
Signed-off-by: ShylajaDevadiga <shylaja.devadiga@suse.com>

Signed-off-by: ShylajaDevadiga <shylaja.devadiga@suse.com>
Co-authored-by: ShylajaDevadiga <shylaja.devadiga@suse.com>
2023-01-18 09:34:52 -08:00
dependabot[bot]
d85952d6a0
Bump ubuntu from 20.04 to 22.04 in /tests/e2e/scripts (#6686)
Bumps ubuntu from 20.04 to 22.04.

---
updated-dependencies:
- dependency-name: ubuntu
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-01-12 13:57:28 -08:00
Derek Nola
674a05478f
Containerd restart testlet (#6696)
* Add containerd testlet to startup integration
* Fix all log dumps
* Stop server gracefully

Signed-off-by: Derek Nola <derek.nola@suse.com>
2023-01-12 13:43:31 -08:00
ShylajaDevadiga
fd8481a29d
Adjust e2e test run script and fixes (#6718)
Signed-off-by: ShylajaDevadiga <shylaja.devadiga@suse.com>
2023-01-11 16:09:45 -08:00
Derek Nola
b5d39df929
Deprecation of etcd-snapshot command in v1.26 (#6575)
* Consolidate etcd snapshot commands
* Consolidate secrets encryption commands
* Move etcd-snapshot to fatal error stage.

Signed-off-by: Derek Nola <derek.nola@suse.com>
2022-12-05 15:28:01 -08:00
Sakala Venkata Krishna Rohit
4e2e91e089
Switch from Google Buckets to AWS S3 Buckets (#6497)
* Add python pip pakacge to install aws cli

Signed-off-by: Venkata Krishna Rohit Sakala <rohitsakala@gmail.com>

* Upload build artifacts to aws s3 instead of gcp bucket

Signed-off-by: Venkata Krishna Rohit Sakala <rohitsakala@gmail.com>

* Upload logs to aws s3 instead of google buckets

Signed-off-by: Venkata Krishna Rohit Sakala <rohitsakala@gmail.com>

* Replace gcloud auth with aws credentials for artifact uploading to buckets

Signed-off-by: Venkata Krishna Rohit Sakala <rohitsakala@gmail.com>

* Replace usage of google bucket with aws s3 buckets

Signed-off-by: Venkata Krishna Rohit Sakala <rohitsakala@gmail.com>

Signed-off-by: Venkata Krishna Rohit Sakala <rohitsakala@gmail.com>
2022-11-28 19:27:43 +02:00
Derek Nola
614da78e43
Add prefer-bundled-bin as an agent flag (#6545)
* Add prefer-bundled-bin as an agent flag
* Add E2E test for prefer-bundled-bin

Signed-off-by: Derek Nola <derek.nola@suse.com>
2022-11-22 13:43:16 -08:00
Derek Nola
0f52088cd3
Add new prefer-bundled-bin experimental flag (#6420)
* initial prefer-bundled-bin ci change
* Add startup testlet
* Convert parsing to pflag library
* Fix code validation
* go mod tidy

Signed-off-by: Derek Nola <derek.nola@suse.com>
2022-11-21 13:01:36 -08:00
ShylajaDevadiga
b276b58175
Convert test output to JSON format (#6410)
* add test output conversion to JSON and minor fixes

Signed-off-by: ShylajaDevadiga <shylaja@rancher.com>
2022-11-04 16:07:12 -07:00
Derek Nola
13c633da12
Add Secrets Encryption to CriticalArgs (#6409)
* Add EncryptSecrets to Critical Control Args
* use deep comparison to extract differences

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

Signed-off-by: Derek Nola <derek.nola@suse.com>
2022-11-04 10:35:29 -07:00
ShylajaDevadiga
d5ffc4b1d1
Add snapshot restore e2e test (#6396)
* Add snapshot and restore test

Signed-off-by: Shylaja Devadiga <shylaja@rancher.com>
2022-11-01 20:04:23 -07:00
James Blair
86be784aa0 Replace deprecated k8s registry references.
Problem:
Previously all of Kubernetes' image hosting has been out of gcr.io. There were significant egress costs associated with this when images were pulled from entities outside gcp.  Refer to https://github.com/kubernetes/k8s.io/wiki/New-Registry-url-for-Kubernetes-(registry.k8s.io)

Solution:
As highlighted at KubeCon NA 2022 k8s infra SIG update, the replacement for k8s.gcr.io which is registry.k8s.io is now ready for mainstream use and the old k8s.gcr.io has been formally deprecated. This commit migrates all references for k3s to registry.k8s.io.

Signed-off-by: James Blair <mail@jamesblair.net>
2022-11-01 16:06:50 -07:00
ShylajaDevadiga
d3c675f4e9
Expand nightly E2E tests (#6354)
Signed-off-by: Shylaja Devadiga <shylaja@rancher.com>
2022-10-31 11:02:44 -07:00
Manuel Buil
ce5dfdfae0
Merge pull request #6359 from manuelbuil/externalTest
Add test for node-external-ip config parameter
2022-10-31 07:35:24 +01:00
Manuel Buil
abaa6c9023 Add test for node-external-ip config parameter
Signed-off-by: Manuel Buil <mbuil@suse.com>
2022-10-28 15:08:50 +02:00
Derek Nola
9a9f1f2d5e
Replace fedora-coreos with fedora 36 for install tests (#6315)
* Move to fedora 36 on install tests

Signed-off-by: Derek Nola <derek.nola@suse.com>
2022-10-27 08:11:57 -07:00
Manuel Buil
487d08ad11 Add a netpol test for podSelector & ingress type
Signed-off-by: Manuel Buil <mbuil@suse.com>
2022-10-26 17:52:28 +02:00
Derek Nola
18688407d9
Add info on libvirt ubuntu 22.04 (#6316)
Signed-off-by: Derek Nola <derek.nola@suse.com>
2022-10-26 08:40:02 -07:00
Derek Nola
fd79a1cfea
Bump testing to opensuse Leap 15.4 (#6337)
* Bump to Leap 15.4 for testing

Signed-off-by: Derek Nola <derek.nola@suse.com>
2022-10-26 08:38:18 -07:00
Manuel Buil
6b804fe224 Add the gateway parameter in netplan
Signed-off-by: Manuel Buil <mbuil@suse.com>
2022-10-18 13:14:10 +02:00
Manuel Buil
dd3f3dba92 Fix dualStack test
Signed-off-by: Manuel Buil <mbuil@suse.com>
2022-10-10 10:52:30 +02:00