Commit Graph
419 Commits
Author SHA1 Message Date
Michael Adam 5c39ac537a build: remove broken make target lint
The lint make target is not used anywhere in the codebase and is particular not run in the CI.
It was recently discovered that `make lint` does not even work at all.
It was subsequently suggested to remove the broken and unused target altogether.

This change settles that issue by removing the lint target and the preparatory
 golint installation target.

Fixes: #15317

Signed-off-by: Michael Adam <obnox@samba.org>
2025-01-24 18:20:49 +01:00
9e725b6214 build: upgrade codegen tooling to the latest version
This includes and is based on the changes of:

https://github.com/rook/rook/pull/14894

Co-authored-by: Blaine Gardner <b.blaine.gardner@gmail.com>
Co-authored-by: subhamkrai <srai@redhat.com>
Signed-off-by: Michael Adam <obnox@samba.org>

Fixes: #14894
2024-12-04 21:00:10 +01:00
Michael Adam 9ecd6a2500 build: support golang 1.23
Signed-off-by: Michael Adam <obnox@samba.org>
2024-09-23 18:07:01 +02:00
Blaine Gardner 5da7feb9d7 test: fix 'make test' on arm mac
make test was failing when running on arm macbooks. Fix it so that it
isn't running with hardcoded GOOS=linux.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2024-08-20 11:19:12 -06:00
Blaine Gardner 33f5407dd4 multus: add host checking to validation tool
In order to help users check that they have implemented the newly-added
Multus host configuration prerequisites, add a check to the validation
tool to verify connectivity.

Because users who are already running clusters with Multus enabled, add
a flag that allows users to only check for host configuration
prerequisites. This mode will not start the large number of clients that
would normally be started because those clients could disrupt a running
Rook cluster negatively.

Host checking pods require host network access. Many Kubernetes
distributions have pod security features enabled. In order to allow
non-Vanilla distros to run this tool, allow specifying a service account
that pods will run as, which can be configured by the admin to allow
test pods.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2024-07-10 13:41:38 -06:00
subhamkrai d116429f75 build: upgrade to go 1.22
this commit upgrade to go 1.22 in go mod file and ci related files.
Also remove go 1.21 support

Signed-off-by: subhamkrai <srai@redhat.com>
2024-07-03 17:01:33 +05:30
Michael Adam 212ecb6a0f build: update to use the latest version of go-junit-report
`make test` failed for me on MacOS with this error:

```console
$ make test

...

=== installing go-junit-report
tar: Error opening archive: Unrecognized archive format
make[2]: ***
$
```

So it seems the version v2.0.0 of go-junit-report has a broken source
tarball

Going to the latest version v2.1.0 fixes the problem for me.

Signed-off-by: Michael Adam <obnox@samba.org>
2024-06-04 17:45:31 +02:00
subhamkrai ea159ad9b7 ci: remove extra comma from platforms
The last pr missed removing the extra comma after the platform
so, instead of ` linux/amd64,linux/arm64,` it should be
` linux/amd64,linux/arm64`.

Signed-off-by: subhamkrai <srai@redhat.com>
2024-05-16 14:47:51 +05:30
subhamkrai f89540c4ef ci: push image ci failing in ubuntu 22.04
since we moved to ubuntu 22.04, ci push image build is failing
due wrong parameter `--platforms linux/amd64 linux/arm64,` it should
be instead `--platforms linux/amd64, linux/arm64`.

Signed-off-by: subhamkrai <srai@redhat.com>
2024-05-15 22:09:16 +05:30
subhamkrai 43e0c1cdb3 build: add support for go 1.22
Few day's back go 1.22 is release. Let's add that
as valid version to build on. Also, adding 1.22 as
test matric for linux build CI.

https://tip.golang.org/doc/go1.22

Signed-off-by: subhamkrai <srai@redhat.com>
2024-03-27 10:34:21 +05:30
subhamkrai dd8c3c9974 build: remove csv related files
remove csv related files/content which are not used/required for
upstream uses.

Signed-off-by: subhamkrai <srai@redhat.com>
2024-03-11 21:01:53 +05:30
Travis Nielsen d77cee791c Merge pull request #13362 from parth-gr/service-account-deafult
core: Set default service account on all Ceph daemons
2024-02-28 10:52:12 -07:00
parth-gr f7a9d8ff7b core: added rook-ceph-default service account
When a private docker registry is used and an
image pull secret is specified in the chart,
the pods with default Service Account fail to pull
the image due to authentication issues.
Added rook-ceph-default service account and modify the pods
specifications by adding the serviceAccountName

closes: https://github.com/rook/rook/issues/12786

Closes: https://github.com/rook/rook/issues/6673
Co-authored-by: Tareq Sharafy <tareq.sha@gmail.com>
Signed-off-by: parth-gr <partharora1010@gmail.com>
(cherry picked from commit 737fb099fe)
Signed-off-by: parth-gr <partharora1010@gmail.com>
2024-02-28 13:32:55 +05:30
Redouane KachachandBlaine Gardner bd7477ec61 manifest: reduce CRD size by removing some descriptions
Reduce CRD size by removing some descriptions for things that
(a) are long, (b) are repeated, and (c) are commong kubernetes types.

Remove the `Status` field from VolumeClaimTemplates (a.k.a. PVCs) in
types.go to remove all unnecessary status-related fields.

Use `yq` to go through generated `crds.yaml` to strip out descriptions
for well-known k8s types that are long and repeated where we can't
remove them from types.go. This is mostly placement descriptions and
volumeSource descriptions.

The overall `crds.yaml` file is reduced to less than 60% of its original
size.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
Signed-off-by: Redouane Kachach <rkachach@redhat.com>
Co-authored-by: Blaine Gardner <blaine.gardner@ibm.com>
2024-02-20 10:08:44 +01:00
Scott Miller e28c107a76 build: fix bad quotation in make help
Signed-off-by: Scott Miller <smiller1@coreweave.com>
2024-01-25 13:01:01 +00:00
travisn 3c1b0692e4 manifest: shorten crd descriptions to 100 chars
Long CRD descriptions were pushing the size of the CRDs manifest
over 1MB, which causes issues when creating the CRDs. To shorten
the manifest, the descriptions are now limited to 100 chars.
This still gives some ability for dev tools to show a brief
description if needed. The generated CRD docs still contain
the full descriptions for reference.

Signed-off-by: travisn <tnielsen@redhat.com>
2024-01-05 09:10:36 -07:00
subhamkrai 0c115927e1 build: remove go1.20 support and default to go1.21
Signed-off-by: subhamkrai <srai@redhat.com>
2023-12-19 11:55:03 +05:30
Blaine Gardner b2d6459f2a doc: update release doc
Update the release doc to include the latest process used to create the
new 1.13 release branch.

Make a few minor changes to the patch update process to keep formatting
the same between new-release-branch and new-patch processes.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2023-12-06 09:43:44 -07:00
Alexander Trost fcf52207f8 build: use /usr/bin/env to look up script interpreters
Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2023-11-21 14:38:22 +01:00
Travis Nielsen 96b24097c2 Merge pull request #13150 from koor-tech/fix_mike_deploy
ci: fix mike deploy flags
2023-11-03 10:11:43 -06:00
Alexander Trost 4a48c14861 ci: fix mike deploy flags
This fixes the docs deploy issues caused by the mike 2.0.0 release that
removed/renamed some flags, see
https://github.com/jimporter/mike/releases/tag/v2.0.0

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2023-11-03 17:03:08 +01:00
travisn 0e0598c155 build: add go modules for apis subdir
To keep the go dependencies minimal, add the go packages
just for the pkg/apis directory. Projects that only reference
the rook apis can then have a smaller footprint for Go
dependencies.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-10-26 16:25:56 -06:00
subhamkrai c4cf300358 ci: skip csv generation for mac
mac build ci is failing during csv gen
when trying to move files to some folder.
Skipping csv gen for mac since it is not required.

Signed-off-by: subhamkrai <srai@redhat.com>
2023-10-25 20:30:24 +05:30
subhamkrai b186150e1c ci: fix mkdocs deprecated imports
migrate to using mkdocs-material's material.extensions.emoji.twemoji
and material.extensions.emoji.to_svg in place of the respective
materialx.emoji.twemoji and materialx.emoji.to_svg. Also, this requires
latest version of mkdocs-material.

Signed-off-by: subhamkrai <srai@redhat.com>
2023-10-18 15:54:46 +05:30
subhamkrai 1b652f8176 build: add check to validate crd in csv
In the past we had few cases where the new crd
was missed adding in metadata-common.yaml file.
So, now we'll check if crds.yaml and metadata-common.yaml
crd name are matching.

Signed-off-by: subhamkrai <srai@redhat.com>
2023-09-06 19:37:25 +05:30
Blaine Gardner 6a0f5fbf42 Merge pull request #12774 from obnoxxx/multus-validation-job-autogen
Multus validation job automated update
2023-08-25 11:51:40 -06:00
Michael AdamandBlaine Gardner 22882c5358 multus: auto-update the validation job manifest file with help text
Signed-off-by: Michael Adam <obnox@samba.org>

this change  introduces a new 'make target 'docs'that generates part of the documentation

It particular, it runs the `helm-docs` target.

Additionally, `make docs`  updates the  multus validation job manifest
by inserting the output of `rook multus validation run --help` between
two newly introduced markers.

The result of running `make docs` is intended to be committed to git after running

Fixes: #12706

Signed-off-by: Michael Adam <obnox@samba.org>
Signed-off-by: Blaine Gardner <b.blaine.gardner@gmail.com>
Co-authored-by: Blaine Gardner <b.blaine.gardner@gmail.com>
Co-authored-by: Michael Adam <obnox@samba.org>

Update build/deploy/generate-deploy-examples.sh

Signed-off-by: Michael Adam <obnox@samba.org>
2023-08-25 18:37:16 +02:00
subhamkrai e9cc7ed7b9 build: update go version to 1.21 from 1.20
Signed-off-by: subhamkrai <srai@redhat.com>
2023-08-25 12:23:21 +05:30
travisn 1a4917de78 build: remove go modules under apis directory
The go package dependencies (go.mod and go.sum) were created
under the pkg/apis directory to simplify the dependencies for
other projects referencing the rook repo. The downside is that
the dependabot can no longer open a working and valid PR since
the bot is not aware of the go.mod and go.sum in the apis directory.

Since the reduction of dependencies for vault in #12455,
the list of extra dependencies is not quite so extensive.
We are putting effort into shrinking the dependency list instead
of using the modules files in the apis subdirectory.

Note that #12419 updated the dependencies for the latest controller
runtime which also increased the size of the modules
list in the pkgs subdirectory, which means the difference
in dependencies in the pkgs subdirectory is no longer
signficant anyway.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-08-21 15:13:33 -06:00
parth-gr 67f294b623 helm: update the default version tag to master
updating this to ease the local testing
using helm for master branch repo

Signed-off-by: parth-gr <paarora@redhat.com>
2023-08-21 20:05:14 +05:30
travisn 05bebc1615 ci: require go 1.20 in the builds
To update to the latest go modules we need to restrict golang
support to 1.20 for now.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-06-22 16:37:10 -06:00
parth-gr 8175bc0218 build: make crds should be able to build generated docs
Currently, if there is any change in the API we need to separately
run the make generate-crd-docs but with this change
make crds will also update the generated docs

Also improved the file locations

Closes: https://github.com/rook/rook/issues/12310

Signed-off-by: parth-gr <paarora@redhat.com>
2023-06-15 20:11:23 +05:30
Javier 9b3e5b10e7 docs: remove the line generated by gen-crd-api-reference-docs
removing the line added by gen-crd-api-reference-docs to avoid commit
specification.md with only the reference to the git commit

Signed-off-by: Javier <sjavierlopez@gmail.com>
2023-06-14 11:35:29 -06:00
s3rj1k dc55f23cba build: add Golang module for APIs
Create separate module for API for external projects to consume.

Signed-off-by: s3rj1k <evasive.gyron@gmail.com>
2023-05-03 21:26:16 +03:00
Javier 661e476969 docs: auto-generate the documentation for CRDs
add generate-crd-docs.sh tool for auto-generate the documentation for CRDs automatically

Closes: #1873
Signed-off-by: Javier <sjavierlopez@gmail.com>
2023-05-01 19:23:27 -06:00
Alexander Trost ecb6ba7383 build: allow overriding variables from a dot env file
This helps forks build custom rook releases more easily by allowing
certain Makefile vars to be overwriten using a `.env` file.
In addition this introduces the `DOCKERCMD` var to the
`build/release/Makefile`.

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
Signed-off-by: Deepika Upadhyay <deepika@koor.tech>
Signed-off-by: Zuhair AlSader <zuhair@koor.tech>
2023-03-31 11:34:07 -04:00
subhamkrai 1112e31511 ci: temporarily skipping another platform to fix the build
temporarily skipping other platforms to fix the build since we are working on bigger changes to remove csv generation.

Signed-off-by: subhamkrai <srai@redhat.com>
2023-03-15 18:34:55 +05:30
parth-grandBlaine Gardner 69ae9569cd build: update k8s version to 1.26.1
Update the Kubernetes API version used to 1.26.1, and start testing
against Kubernetes version 1.26.1 in CI.

Co-authored-by: parth-gr <paarora@redhat.com>
Co-authored-by: Blaine Gardner <blaine.gardner@redhat.com>

Signed-off-by: parth-gr <paarora@redhat.com>
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2023-02-23 20:18:47 -07:00
Blaine Gardner 442e6480bd build: allow building on Mac with Apple silicon
There are a couple minor changes needed to allow building Rook on Apple
silicon.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2023-02-22 17:32:42 -07:00
Travis Nielsen 2a8be0513a Merge pull request #11668 from subhamkrai/update-csv-gen-script
build: clean rbac which are not required
2023-02-17 11:12:09 -07:00
subhamkrai 4699e8885a build: add rbac which are required
adding necessary rbac and also updating
csv-gen script.

Closes: https://github.com/rook/rook/issues/10141
Signed-off-by: subhamkrai <srai@redhat.com>
2023-02-17 23:00:03 +05:30
parth-gr b81ee215a7 build: update golang version to v1.19
Updated the go mod and ci to use gov1.19 as
minimum and removed support for go1.18

Closes: https://github.com/rook/rook/issues/11681
Signed-off-by: parth-gr <paarora@redhat.com>
2023-02-17 18:39:05 +05:30
subhamkrai 45a10dcb85 core: upgrade to latest operator-sdk v1.25.0
upgrading to latest operator-sdk later version
and changing the way of csv generation.

Signed-off-by: subhamkrai <srai@redhat.com>
2023-02-13 17:08:09 +05:30
Alexander Trost b12569c423 docs: add release instructions
Thanks to @travisn for providing his release procedure notes!

Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2023-01-19 19:01:45 +01:00
Khris Richardson fca7d44c3f manifest: revert fix unexpected end of stream
Signed-off-by: Khris Richardson <khris.richardson@gmail.com>
2022-12-07 13:40:35 -08:00
Zuhair 792a261ca9 docs: auto generate helm chart docs using helm-docs
Signed-off-by: Zuhair AlSader <zuhair@koor.tech>
2022-12-02 17:08:50 -05:00
Alexander Trost 1724cdcb92 build: use script to reliably determine latest released release branch
Signed-off-by: Alexander Trost <galexrt@googlemail.com>
2022-09-20 23:38:45 +02:00
Travis Nielsen 7863d3161c build: fix intermittent gen-rbac failure
The crds generation for the helm crds is intermittently hitting a build
error due to multiple builds generating the crds at the same time.
We avoid this race condition by first writing the crds to a temp file
then move the file to the helm crd resources file.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-09-14 16:10:51 -06:00
Travis Nielsen 839920ff80 build: stop printing verbose rbac generation details
The rbac generation prints a lot of info that is not necessary
unless troubleshooting the rbac build, so we can comment it
out by default.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-09-13 11:26:51 -06:00
Deepika Upadhyay ccbff1be95 ci: add debug flag to identify any failing yaml origin
Signed-off-by: Deepika Upadhyay <deepika@koor.tech>
2022-09-09 23:30:51 +05:30