Commit Graph
535 Commits
Author SHA1 Message Date
subhamkrai dab921c82a ci: update go mod and go version in govulncheck
this commits updates the go version to 1.22.2 in govulncheck ci and
also updates golang.org/x/net to v0.23.0 to fix the ci

Signed-off-by: subhamkrai <srai@redhat.com>
(cherry picked from commit f063e8fe39)
Signed-off-by: subhamkrai <srai@redhat.com>
2024-04-08 12:09:17 +05:30
NymanRobin 38503b9b44 ci: remove minor version from setup-go in govulncheck
The patch version was pinned which caused problems
with security patches. Unpin it and always check
for new patch version

Signed-off-by: NymanRobin <nyman.robin@gmail.com>
(cherry picked from commit fdacd1e587)
2024-03-07 13:17:45 +00:00
Liang Zheng d13cc7731d osd: support create osd with metadata partition
Currently, when rook provisions OSDs(in the OSD prepare job), rook effectively run a
c-v command such as the following.
```console
ceph-volume lvm batch --prepare <deviceA> <deviceB> <deviceC> --db-devices <metadataDevice>
```
but c-v lvm batch only supports disk and lvm, instead of disk partitions.

We can resort to `ceph-volume lvm prepare` to implement it.

Signed-off-by: Liang Zheng <zhengliang0901@gmail.com>
(cherry picked from commit ee05e82cea)
2024-02-08 21:21:05 +00:00
sp98 ba470a54dd ci: fix ci failure for multicluster tests
This PR fixes the failure while running multicluster mirroring CI tests

Signed-off-by: sp98 <sapillai@redhat.com>
(cherry picked from commit 45adae1931)
2024-02-06 10:42:44 +00:00
Blaine Gardner 5e53ce16a6 ci: fix detection of GH actions extra disk
The 'extra' block device attached to GH actions runners has changed size
twice in 3 months. The previous strategy of detecting the disk by size
is becoming harder to maintain. Additionally, the block size with recent
changes (75G) is now the same as the boot device (also 75G), making the
method inexact.

The method can now be summarized as, "find the boot disk and choose the
disk that isn't the boot disk to be the 'extra' one used."

Prior to this, we used a one-liner based on `lsblk`. While we could
still make this a one-liner, the method is now updated to 2 effective
lines, plus debug text output to stderr to help if we need to debug
further in the future.

Of note, the 'extra' disk has a mount point of "/mnt", but it is unclear
whether this is a reliable heuristic for detecting the extra disk. For
years now, GH action runners have had only 2 disks. Therefore, it seems
slightly more likely that a heuristic to "choose the non-boot disk" will
be a more robust long-term solution.

If this strategy proves to be unreliable in the future, it may be wise
to consider whether "the device with a partition mounted to '/mnt'"
would be a good alternative.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
(cherry picked from commit feacb6424e)
2024-02-06 02:10:55 +00:00
subhamkrai 7f2b60681d ci: disk in github action increased to 75G from 64G
the disk size in the github action machine has
increased from 64G to 75G. Now, we detech the version
automatically not fetching hard coded value.

Co-authored-by: Jan Klippel <jan.klippel@uhurutec.com>
Signed-off-by: subhamkrai <srai@redhat.com>
(cherry picked from commit 6b0deb32d9)
2024-02-05 17:29:54 +00:00
Blaine Gardner 8d3e6f2dc5 ci: check for gofmt usage in golangci-lint
This is needed because not all contributors may be using gomft to format
source code, and this could result in inconsistent usage over time.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
(cherry picked from commit c98ce0a56b)
2024-02-01 19:13:09 +00:00
parth-gr a201cda3da external: honour support of cluster-name legacy flag
we have changed the --cluster-name flag to --k8s-cluster-name
but to support automation while upgrade we should support
the legacy flag

Signed-off-by: parth-gr <partharora1010@gmail.com>
(cherry picked from commit 8e4ec01cbb)
2024-01-09 11:42:15 -07:00
Ryotaro Banno 8c98474418 ci: wait for all OSD pods to become Running in wait_for_prepare_pod
Currently, `wait_for_prepare_pod` only waits until 1 prepare pod and 1
OSD pod are in Running state.

So if `wait_for_ceph_to_be_ready` failed after `wait_for_prepare_pod`
succeeded, there are 4 possible cases:

1. some prepare pods didn't start correctly;
2. some prepare pods didn't finish correctly;
3. some OSD pods didn't start correctly; or
4. all prepare pods and OSD pods worked correctly, but some other
   process failed.

As far as I understand, the number of prepare pods on the GitHub CI is
always 1, so cases 1 and 2 are not problematic. However, it is hard to
distinguish the other two cases from the CI log.

To solve the above problems, this patch makes wait_for_prepare_pod wait
for all OSD pods to become running state. If wait_for_prepare_pod
timeouts before the OSD pods become running state, this will be a strong
indication that the OSD pods didn't start properly (i.e., case 3).

Signed-off-by: Ryotaro Banno <ryotaro.banno@gmail.com>
(cherry picked from commit e9c1f81d79)
2023-12-26 08:15:37 +00:00
Travis Nielsen e11774ad05 Merge pull request #13445 from rook/mergify/bp/release-1.13/pr-13441
ci: improve collect-log script (backport #13441)
2023-12-19 10:56:37 -07:00
subhamkrai d3ae92c6ef ci: improve collect-log script
I was debugging helm tests, I noticed, the operator namespace
content is empty and operator is created in same namespace as
other pods. Also, let's collect the 'kube-system' namespace logs
in multus test only as that is the only test where we need to debug
cluster networking and require kube-system logs.

Signed-off-by: subhamkrai <srai@redhat.com>
(cherry picked from commit 2d3e561a00)
2023-12-19 09:32:03 -07:00
dependabot[bot] 75b0eeee05 build(deps): bump actions/upload-artifact from 3 to 4
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 3 to 4.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
(cherry picked from commit 4782ccf5ad)
2023-12-18 17:25:56 +00:00
subhamkrai 48ecb3e55f ci: upgrade kubernetes version to latest version
Signed-off-by: subhamkrai <srai@redhat.com>
(cherry picked from commit 54b3c9f79f)
2023-12-15 09:14:51 -07:00
subhamkrai 8121c4046f ci: fix multi-cluster-mirroing canary-test
use `sed` to update all the namespace in filesystem-test.yaml file.
Since with subvolumegroup CR added there are more than one `namespace: *`
present and only one was updating by yq command.

Signed-off-by: subhamkrai <srai@redhat.com>
(cherry picked from commit c05578a019)
2023-12-13 16:33:12 +00:00
subhamkrai 0b13693678 ci: update go version in govulncheck
updating go version from `1.21.4` to `1.21.5`.

Signed-off-by: subhamkrai <srai@redhat.com>
(cherry picked from commit ccaffd935f)
2023-12-08 14:12:12 +00:00
travisn 83caa1b2bf core: fix golang linter issues with variables in loops
Loop variables cannot be reliably uses since they will
change with each iteration. Update these loop variable
uses to be safe by indexing the slice rather than
using the loop variable directly.

Also suppress the linter issues for passwords used
in tests.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit 6f8e42422d)
2023-12-05 21:47:35 +00:00
travisn cc85f6524f ci: correct version of k8s 1.25.x
The K8s v1.25.17 release does not exist, which was mistakenly
set in the CI for the master and release tests. Now we revert
it back to v1.25.16.

Signed-off-by: travisn <tnielsen@redhat.com>
(cherry picked from commit 5fc7237339)
2023-12-04 20:05:21 +00:00
Anthony D'Atri d5c86cf13a doc: improve ceph-csi-drivers.md and lintrolling
Signed-off-by: Anthony D'Atri <anthonyeleven@users.noreply.github.com>
(cherry picked from commit 59d0240676)
2023-12-04 17:12:20 +00:00
parth-gr df7c401d35 external: add support for rados namespace for external cluster
change the json output of storageclass to also inclusde rados namespace,
and also added the changes in the csi secret

Signed-off-by: parth-gr <paarora@redhat.com>
2023-11-28 11:52:30 +05:30
Blaine Gardner cbd9c8fe74 test: add tmate to daily/nightly jobs
Add tmate debugging to daily/nightly jobs to help debugging.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2023-11-21 09:29:28 -07:00
subhamkrai 39e41ed8d7 ci: upgrade min k8s support to 1.23.17
Upgrade minimum kubernetes support to 1.23.17 from 1.22.17.
Also, upgrade kubernetes version latest minor release.

Signed-off-by: subhamkrai <srai@redhat.com>
2023-11-17 13:06:46 +05:30
travisn 03d077aa6b core: remove support for ceph pacific
Pacific is end of life and no longer necessary to
support in Rook with v1.13.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-11-14 17:07:03 -07:00
dependabot[bot] 27ab069863 build(deps): bump dcarbone/install-jq-action from 2.0.2 to 2.1.0
Bumps [dcarbone/install-jq-action](https://github.com/dcarbone/install-jq-action) from 2.0.2 to 2.1.0.
- [Release notes](https://github.com/dcarbone/install-jq-action/releases)
- [Commits](https://github.com/dcarbone/install-jq-action/compare/v2.0.2...v2.1.0)

---
updated-dependencies:
- dependency-name: dcarbone/install-jq-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-11-13 12:32:26 +00:00
Travis Nielsen 383dfda153 Merge pull request #13187 from subhamkrai/fix-govul
ci: add go 1.21.4 in govulncheck ci run
2023-11-09 09:28:41 -06:00
subhamkrai a878e52ba7 ci: add go 1.21.4 in govulncheck ci run
In, go 1.20 govulncheck ci is failing due to
some vulnerabilities which affects windows
machine and rook is not used in windows machine.
The solution is to update go version to 1.21.4

Signed-off-by: subhamkrai <srai@redhat.com>
2023-11-09 19:25:30 +05:30
dependabot[bot] df5527ce25 build(deps): bump helm/chart-testing-action from 2.6.0 to 2.6.1
Bumps [helm/chart-testing-action](https://github.com/helm/chart-testing-action) from 2.6.0 to 2.6.1.
- [Release notes](https://github.com/helm/chart-testing-action/releases)
- [Commits](https://github.com/helm/chart-testing-action/compare/v2.6.0...v2.6.1)

---
updated-dependencies:
- dependency-name: helm/chart-testing-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-11-07 15:49:02 +00:00
sp98 345f92961b ci: filter both 14 and 64 disks in CI
github ci runner is allocating both 14 and 64 Gb disks to the setup.
Rook CI currently hard codes the lsblk with a 14G filter.
This PR updates the filter to use either 14G or 64G disks.

Signed-off-by: sp98 <sapillai@redhat.com>
2023-11-06 13:30:10 +05:30
dependabot[bot] 0fdaf5a8ca build(deps): bump wagoid/commitlint-github-action from 5.4.3 to 5.4.4
Bumps [wagoid/commitlint-github-action](https://github.com/wagoid/commitlint-github-action) from 5.4.3 to 5.4.4.
- [Changelog](https://github.com/wagoid/commitlint-github-action/blob/master/CHANGELOG.md)
- [Commits](https://github.com/wagoid/commitlint-github-action/compare/v5.4.3...v5.4.4)

---
updated-dependencies:
- dependency-name: wagoid/commitlint-github-action
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-11-02 21:55:14 +00:00
travisn dfa522d906 ci: update helm linter to v2.6.0
The helm linter was failing with v2.4.0. Now
update the version of the action to the latest
and greatest.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-10-31 11:20:57 -06:00
Blaine Gardner 76b90e1a96 Merge pull request #13097 from step-security-bot/stepsecurity_remediation_1698170726
ci: Harden GitHub Actions permissions
2023-10-24 12:25:14 -06:00
StepSecurity Bot beef4e2cde test: limit permissions in github actions
Automatic PR from app.stepsecurity.io (initiated by BlaineEXE) to limit 
permissions in github actions to only those needed.

Signed-off-by: StepSecurity Bot <bot@stepsecurity.io>
2023-10-24 18:05:30 +00:00
Blaine Gardner f90e069ba9 test: add govulncheck to look for go vulnerabilities
govulncheck is a static code analyzer that scans more deeply than Snyk.
Additionally, because govulncheck checks the code itself, it can rule
out vulnerabilities that are present in dependencies but that are not
used in Rook's code path.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2023-10-24 11:47:10 -06:00
Travis Nielsen 703f594f4c Merge pull request #12860 from parth-gr/mds-liveness
mds: improve the mds liveness probe calls
2023-10-10 08:21:00 -06:00
parth-gr 3d4036547c ci: check mds liveness probe unit test from the CI run
Signed-off-by: parth-gr <paarora@redhat.com>
2023-10-10 18:56:36 +05:30
parth-gr 98125c78b9 ci: add a test to check the script result in idempotent output
Signed-off-by: parth-gr <paarora@redhat.com>
2023-10-05 19:48:38 +05:30
Blaine Gardner 0c721e05d5 multus: allow node profiles in validation test
Add the ability to specify node profiles in the multus validation test.

This addresses a few points of early feedback on the validation tool.
Statements below critique the tool's behavior before this patch.
1. The tool assumes all daemons are on public and cluster network, which
   means users who have a significantly smaller cluster net (a
   design choice) cannot run a single test to determine if Rook is
   likely to install correctly.
2. The tool does not have placement options to select only a subset of
   Kubernetes nodes to run validation on.
3. Users of multus seem to have a dedicated pool of storage nodes more
   often than the average Rook install. This makes sense for security-
   and perforance-minded users. The tool cannot run a single test to
   verify storage-only and general-workload nodes at one time.

These points are addressed by allowing users to specify configurations
for different "NodeTypes."

Each NodeType config has options for selecting the number of OSDs as
well as the number of other (non-OSD) Ceph daemons. This limits the
unnecessary exhaustion of cluster network addresses from critique 1.

Each NodeType config has its own placement (critique 2).

Users can define as many NodeTypes as needed to test the network for
their planned CephCluster. Specifically, this allows the tool to test
storage-only nodes and generalized-workload nodes at the same time. An
arbitrary number of NodeTypes are allowed to support even more highly
specialized cluster setups, such as multiple tiers of storage nodes
where some storage-only nodes may run more OSDs than others.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2023-10-04 15:26:35 -06:00
Blaine Gardner bf9e5dc1f5 ci: make use of caching in actions/setup-go
The GH action to set up Golang (actions/setup-go) has cache
functionality. For cache hits, this saves ~2 minutes for each run. In
order for the cache to hit, caching must not be disabled, and the code
must be checked out before setting up Golang.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2023-10-04 13:41:56 -06:00
Redouane Kachach b3dd74ea20 docs: fixing some spelling issues
closes: https://github.com/rook/rook/issues/12987

Signed-off-by: Redouane Kachach <rkachach@redhat.com>
2023-10-03 13:50:17 +02:00
subhamkrai e14f8c7710 ci: remove workaround for clean disk action
The issues are fixed from the clean disk action
repo and we shouldn't require any workaround. Also,
I'm not using git revert to revert the commit is earlier
clean disk action was mentioned in every CI which was
duplicate and now we have placed the action to composite yaml

Signed-off-by: subhamkrai <srai@redhat.com>
2023-09-29 19:17:01 +05:30
subhamkrai 3267576307 ci: fix github action free disk space
Since `google-cloud-sdk` is renamed with `google-cloud-cli`,
the github action is failing to remove the older name and this
is causing ci issues. Applying changes suggested by community to
manually remove some packages to resolve the issue.

Signed-off-by: subhamkrai <srai@redhat.com>
2023-09-28 18:56:59 +05:30
travisn 0a4ce46727 ci: skip encryption pvc kms test if needed
The skip_ci label was not being respected by the
encryption-pvc-kms-ibm-kp canary test.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-09-25 11:17:23 -06:00
d3bc9aafee ci: suppress snyk MPL license warnings
Fixes: #12930

This patch introduces a  .snyk policy file that lets snyk suppress the warnings
 about  the MPL license in projects pulled in as dependencies.

Additinally, this  fixes a typo in the name of the snyk workflow
file

Signed-off-by: Michael Adam <obnox@samba.org>
Co-authored-by: Travis Nielsen <tnielsen@redhat.com>
Co-authored-by: Blaine Gardner <b.blaine.gardner@gmail.com>
2023-09-25 19:10:15 +02:00
Blaine Gardner 750ae02265 Merge pull request #12922 from BlaineEXE/update-multus-canary-test
test: update multus canary test
2023-09-19 11:28:13 -06:00
Blaine Gardner 3e2e906ea7 test: update multus canary test
Update the multus canary test to reflect modern knowledge about how it
should be configured.

No longer test for the network device in OSD pods. Pods will utterly
fail to start if Multus is unable to attach interfaces.
Instead, look to the OSD map to test the connections more wholistically.
OSDs must have map IPs that include both public and cluster network.
This implicitly tests that the interfaces exist in the Pod, and it
additionally verifies other details, like Ceph `*_network` configs are
set propertly.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2023-09-18 17:15:23 -06:00
Travis Nielsen 950a0e861c Merge pull request #12917 from rook/dependabot/github_actions/aws-actions/configure-aws-credentials-4
build(deps): bump aws-actions/configure-aws-credentials from 3 to 4
2023-09-18 07:41:37 -06:00
dependabot[bot] 3db03cd9a0 build(deps): bump aws-actions/configure-aws-credentials from 3 to 4
Bumps [aws-actions/configure-aws-credentials](https://github.com/aws-actions/configure-aws-credentials) from 3 to 4.
- [Release notes](https://github.com/aws-actions/configure-aws-credentials/releases)
- [Changelog](https://github.com/aws-actions/configure-aws-credentials/blob/main/CHANGELOG.md)
- [Commits](https://github.com/aws-actions/configure-aws-credentials/compare/v3...v4)

---
updated-dependencies:
- dependency-name: aws-actions/configure-aws-credentials
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-18 12:41:43 +00:00
dependabot[bot] 22bae1cccd build(deps): bump docker/login-action from 2 to 3
Bumps [docker/login-action](https://github.com/docker/login-action) from 2 to 3.
- [Release notes](https://github.com/docker/login-action/releases)
- [Commits](https://github.com/docker/login-action/compare/v2...v3)

---
updated-dependencies:
- dependency-name: docker/login-action
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-18 12:41:40 +00:00
cef43e1155 build: update s5cmd to version v2.2.1
This is the latest available version.
The previously used version v2.0.0 was very outdated.

Fixes: #12883

Co-authored-by: subham rai subhamkrai <srai@redhat.com>
Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Subham Rai subhamkrai <srai@redhat.com>
  signed-off-by: Travis Nielsen <tnielsen@redhat.com>
    Co-authored-by: Travis Nielsen <tnielsen@redhat.com>
2023-09-15 16:16:47 +02:00
dependabot[bot] 14f0a9e772 build(deps): bump actions/checkout from 3 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-04 12:33:02 +00:00
Travis Nielsen 3468a4a43f Merge pull request #12816 from obnoxxx/simplify-workflow
Simplify docs-check workflow by extracting functionality
2023-09-01 11:32:00 -06:00