Commit Graph
234 Commits
Author SHA1 Message Date
Blaine Gardner 01d7b22cf1 build: update base and manifests to ceph v18.2.1
Update Rook operator base image and example manifests to the latest Ceph
version released late last week v18.2.1.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2023-12-18 11:27:52 -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
Blaine Gardner db1ca8c93e multus: use rook image for ip range detection
Use the Rook image (defined by the operator pod) to detect the Multus
network address ranges. It is reasonable for users to want to have a
minimal Ceph image that does not have the `ip` utility installed, which
is used for detecting the address ranges of multus interfaces. Instead,
use the Rook image, which Rook can ensure has the `ip` tool if Ceph ever
removes it from their image.

Signed-off-by: Blaine Gardner <blaine.gardner@ibm.com>
2023-11-08 10:11:04 -07:00
travisn fdb72adb8f core: update operator base image to reef
Reef object store configuration may have issues due to
the operator base image being Quincy, while trying
to deploy a Reef cluster. There appear to be forward
compatibility issues with the radosgw-admin command.
Now the base image is updated to v18.2.0 to better
handle the compatibility across ceph versions.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-10-25 15:26:16 -06: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
Jiffin Tony Thottan b48dc8a335 object: intial cosi driver controller design
Adding CephCOSIDriver CRD and controller. The controller will bring up
the ceph cosi driver when first object store is created in the rook
operator namespace. Then admin can defined COSI CRDs like BucketClass
and BucketAccessClass for different object stores deployed via Rook.
Using the BucketClass and BucketAccessClass, user can define
BucketAccess for backend bucket in the RGW. The CephCOSIDriver CRD
defines configuration options for ceph cosi driver. In the first version
its usability is minimal. Even if it is not defined Rook will bring up
the ceph cosi driver with default values.

Signed-off-by: Jiffin Tony Thottan <thottanjiffin@gmail.com>
2023-07-18 22:49:41 +05:30
travisn 609ac91cb1 core: update default image to ceph v17.2.6
With the release of ceph v17.2.6, the examples and the base
image for the operator are updated to pick up the latest
and greatest.

Signed-off-by: travisn <tnielsen@redhat.com>
2023-04-11 14:07:11 -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 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
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
Travis Nielsen 4f77664862 manifest: toolbox and jobs mount secret volume
The toolbox, toolbox job, and osd prepare jobs need to mount the
ceph admin keyring as a file instead of using an env var.
The toolbox script will still allow setting of the env var
for backward compatibility, though all the examples are now
updated to use the keyring as a file.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-12-14 21:44:59 -07:00
Pratik Raj db9bd9f918 security: update "s5cmd" to "v2.0.0"
update "s5cmd" to "v2.0.0" as "1.4.0" was built using go v1.16 and has many vulnerabilities

Resolves #11176

Signed-off-by: Pratik Raj <rajpratik71@gmail.com>
2022-10-27 14:56:15 +05:30
subhamkrai 270b565f18 core: upgrade ceph to latest release v17.2.5
Signed-off-by: subhamkrai <srai@redhat.com>
2022-10-26 19:59:53 +05:30
Travis Nielsen f02fadc531 manifest: update default version of ceph to v17.2.3
For the Rook v1.10 release we want the latest version of Quincy to
be the default deployment. Updating to v17.2.3 with the latest
patch release.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-08-11 16:55:03 -06:00
Travis Nielsen 4d8cbaac83 build: remove obsolete image base var
The OSBASE and OSBASEIMAGE are obsolete from an older version
of rook where Ceph was not the base image. Now that Ceph provides
the base image, there is no need for these vars in the makefile.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-07-26 11:57:49 -06:00
Travis Nielsen eb08b009ba build: update to latest quincy release 17.2.1
With the latest quincy release, we update the operator base image
and examples to use 17.2.1

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-06-24 15:57:19 -06:00
parth-gr 38dcf09843 build: update examples and base image to use ceph v17.2.0 quincy version
The operator base image has been changed to
ceph v17.2.0 quincy release version `quay.io/ceph/ceph:v17.2.0`

Closes: https://github.com/rook/rook/issues/10140
Signed-off-by: parth-gr <paarora@redhat.com>
2022-06-07 12:55:47 +05:30
Madhu Rajanna 15da42cf0c csi: change sidecar images repo to new link
Change sidecar images repo to registry.k8s.io
which is a redirect to k8s.gcr.io.

Ref: https://github.com/kubernetes/k8s.io/wiki/
New-Registry-url-for-Kubernetes-(registry.k8s.io)

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2022-06-06 11:02:38 +05:30
parth-gr 09d52511ad rgw: validate rgw endpoint ip
The ceph-external-cluster-details-exporter.py
generates the json output even with
rgw-endpoint IP from different cluster
Added a check validate_rgw_endpoint which will validate
the above rgw_endpoint Ip by matching the cluster fsid

Signed-off-by: parth-gr <paarora@redhat.com>
2022-05-11 19:52:30 +05:30
Madhu Rajanna 52c8211e43 csi: use k8s.gcr.io for csi nfsplugin image
use k8s.gcr.io like other kubernetes sidecar
image to pull the nfsplugin image.

Signed-off-by: Madhu Rajanna <madhupr007@gmail.com>
2022-04-13 11:54:35 +05:30
Rakshith R 34162c3dc5 csi: add nfs nodeplugin daemonset
This commit adds nfs nodeplugin daemonset.
This will allow rook to deploy nfs nodeplugin
which can mount/unmount nfs volumes.

refer:
- https://github.com/ceph/ceph-csi/blob/devel/docs/design/proposals/nfs.md
- https://github.com/kubernetes-csi/csi-driver-nfs

Signed-off-by: Rakshith R <rar@redhat.com>
2022-04-12 11:07:38 +05:30
Travis Nielsen 738a300827 build: remove obsolete cross build container
The cross build container is not used anymore since the conversion
to github actions. Now the obsolete scripts and makefiles are
cleaned up to remove some confusing leftovers from the
cross container.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-04-07 13:42:18 -06:00
Travis Nielsen d86bb78f11 build: add volume replication crds to csv ownership
The volume replication crds are not owned by rook, but if installing
with the csv, ownership must be specified for the CRDs. Thus, we limit
ownership to the csv for the volume replication crds.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-03-09 15:53:43 -07:00
Travis Nielsen a98678585a build: update ceph base image to v16.2.7-20220216
The latest ceph image should be used for the base of
the rook image to pick up the latest security releases.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2022-02-28 11:21:49 -07:00
Sébastien Han 0a918814ea core: bump to ceph 16.2.7
ceph 16.2.7 is out so let's use it in our manifests.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-12-08 17:24:56 +01:00
Blaine Gardner 2c4b66957c build: generate CSV from helm charts
In order to generate common.yaml from Helm charts, we have to have a
different way of generating CSV than from meta-comments in common.yaml.
This implementation changes what appears in the CSV's RBAC somewhat, but
these changes could be considered bugs fixed by using the new Helm
generation method.
- a few PSP related resources are removed from CSV
- resources related to 'rook-ceph-purge-osd' Job are added to CSV
- ClusterRoleBinding 'rook-ceph-object-bucket' is added to CSV

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2021-11-30 08:35:54 -07:00
Blaine Gardner 51fc36d591 build: prevent parallel build collisions for ceph
Prevent parallel build collisions in the 'ceph' image by building
prerequisites for the builds before running the build targets in
parallel. Build targets can collide and try to create the same target at
nearly the same time, causing failures.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2021-11-30 08:09:24 -07:00
Blaine Gardner 113e2f849d build: use yq for RBAC yaml parsing
Use yq instead of Python for parsing RBAC from the Helm chart. We need
to use yq v4.14.1 or higher to fix yq's handling of the yaml header
markers ('---'). Update the Makefile's yq version to v4, which also
requires updating the script to update the CRDs. This was quite easy.

It is very difficult, however, to change the version of yq used by the
CSV generating/parsing scripts, which already used their own yq
download. Continue using yq v3 for this.

In order to make sure the scripts are using the right version of yq, add
basic validation to them to verify they are running v3 or v4 as required
for their operation.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2021-11-30 08:08:08 -07:00
Sébastien Han c890710b63 core: change directory layout
As per discussion, proposing a new layout for the charts/yaml/olm files.

./deploy
├── charts
│   ├── rook-ceph
│   │   └── templates
│   └── rook-ceph-cluster
│       └── templates
├── examples
│   ├── csi
│   │   ├── cephfs
│   │   └── rbd
│   ├── flex
│   ├── monitoring
│   ├── pre-k8s-1.16
└── olm
    └── assemble

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-30 09:12:53 +01:00
Sébastien Han 619f5eee6e build: revert "build: images/cross/Dockerfile to reduce vulnerabilities"
This reverts commit ceec0bc48c. The build
is failing to push images to master. This is not a critical update so
let's remove.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-25 14:53:21 +01:00
snyk-bot ceec0bc48c build: images/cross/Dockerfile to reduce vulnerabilities
The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-UBUNTU1604-LIBGCRYPT20-1585790
- https://snyk.io/vuln/SNYK-UBUNTU1604-SYSTEMD-1320131
- https://snyk.io/vuln/SNYK-UBUNTU1604-SYSTEMD-1320131
- https://snyk.io/vuln/SNYK-UBUNTU1604-SYSTEMD-1320131
- https://snyk.io/vuln/SNYK-UBUNTU1604-SYSTEMD-1320131

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-25 11:59:22 +01:00
snyk-bot 38b2af711a build: images/cross/Dockerfile to reduce vulnerabilities
The following vulnerabilities are fixed with an upgrade:
- https://snyk.io/vuln/SNYK-UBUNTU1604-LIBGCRYPT20-1585790
- https://snyk.io/vuln/SNYK-UBUNTU1604-SYSTEMD-1320131
- https://snyk.io/vuln/SNYK-UBUNTU1604-SYSTEMD-1320131
- https://snyk.io/vuln/SNYK-UBUNTU1604-SYSTEMD-1320131
- https://snyk.io/vuln/SNYK-UBUNTU1604-SYSTEMD-1320131

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-24 15:38:15 +01:00
Travis Nielsen 59729765bf build: default to amd64 arch for the the s5cmd tool
On mac, the docker build was failing due to an unspecified
S5CMD_ARCH. Now we default to build amd64 always and override
it if the arch is arm64.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-11-10 12:25:57 -07:00
Sébastien Han 889856b78f core: add s5cmd binary to operator image
The toolbox can now interact with S3 gateways using the `s5cmd` tool.
The binary is only 12M so this does not add up too much to the operator
image size.

Closes: https://github.com/rook/rook/issues/4968
Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-09 16:56:30 +01:00
Sébastien Han 3b85de420f Merge pull request #8744 from leseb/fix-8734
ceph: run operator with rook user
2021-11-05 17:56:54 +01:00
Sébastien Han d06a6f93a5 core: run operator with rook user
The rook operator as well as the toolbox pod run with the "rook" user
with UID 2016. The UID was chosen based on the year of the initial
commit in the rook/rook repository.
No more root user running.

Closes: https://github.com/rook/rook/issues/8734
Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-05 17:22:04 +01:00
Sébastien Han 6fb67a297d build: only produce binary for linux
We now build rook to build only for linux platforms and not darwin nor
windows anymore.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-11-04 15:13:40 +01:00
Travis Nielsen 9655e3a21e Merge pull request #8927 from synarete/aarch64-graviton
build: support build of rook on aarch64 (AWS/graviton)
2021-10-20 07:55:20 -06:00
Blaine Gardner 221281cab3 build: fix offline image build race condition
When generating the offline image list, the threaded crossbuild can
try to generate the image list from muliple jobs at once, resulting in
undefined behavior (usually an empty file) for the output file. To fix
this, we can generate this file in the `build.common` step which is not
run in parallel.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2021-10-11 16:07:28 -06:00
Travis Nielsen c420f2309c csi: no longer install the volumereplication crds from rook
The volume replication CRDs are an external component, not owned by Rook.
Therefore, they should be installed as any other independent component
in case the admin will install other consumers of the volumereplication CRDs
in the future in addition to Rook and the CSI driver.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-10-06 16:27:44 +00:00
Shachar Sharon c3e2c77da6 build: support build of rook on aarch64 (AWS/graviton)
Build rook in AWS/Graviton (ARM64) platform. Upon installation of
operator-sdk, make sure that the downloaded binary can actually be
executed on local machine by invoking 'operator-sdk version'.

issue: https://github.com/rook/rook/issues/8926

Signed-off-by: Shachar Sharon <ssharon@redhat.com>
2021-10-06 18:29:00 +03:00
Blaine Gardner 24bf99f31c build: use intermediate tmp for offline image gen
Reading from a file, processing the file in a pipe, and outputting the
piped content to the same file can have undefined results, often leading
to an empty file. Use an intermediate temp file for generating the
offline image list.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2021-09-29 17:31:02 -06:00
subhamkrai 2d7755ca15 build: update command to generate image list
While build.all we have race condition where images.txt
file was update with duplicate entries. So, removing `-a`
from 1st tee and also add `sort -h`and `uniq` command to
confirm no duplicate entry is in the file.

Signed-off-by: subhamkrai <srai@redhat.com>
2021-09-29 15:00:05 +05:30
Sébastien Han 121c2987e3 ceph: stop using tini
We don't need to use tini.
We don't have anything in the rook operator that would
either create zombie processes (no threads) or use
exec (to fork). The Go binary has a really good
signal handling mechanism.

Closes: https://github.com/rook/rook/issues/8794
Signed-off-by: Sébastien Han <seb@redhat.com>
2021-09-27 10:54:16 +02:00
Travis Nielsen 0a0b9c98bd build: remove obsolete flex driver
The flex driver has been fully deprecated and thus removed from Rook.
Before upgrading to v1.8, users will need to convert existing flex volumes
from flex to csi volumes.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-09-23 16:17:20 -06:00
Travis Nielsen fb74e7b2d5 ceph: pick up latest ceph base image 16.2.6-20210918
The previous base image in use by rook v16.2.6-20210916 disappeared
from quay.io.

Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
2021-09-23 15:11:34 -06:00
Sébastien Han 0c33493f27 ceph: bump manifests to ceph pacific 16.2.6
New version is out so let's use it.

Signed-off-by: Sébastien Han <seb@redhat.com>
2021-09-21 09:16:32 +02:00
subhamkrai 284dbc0a0e build: use pkg/operator/ceph/csi/spec.go for csi images
it has happened more than once that the manifests do not
reflect the images so now reading from `pkg/operator/ceph/csi/spec.go`
as this what code uses.

Closes: https://github.com/rook/rook/issues/8687
Signed-off-by: subhamkrai <srai@redhat.com>
2021-09-13 17:16:52 +05:30
subhamkrai 7bc9a138f2 ci: image list for offline installation
create file tests/scripts/rook-ceph-image.txt which
will have list of images required for offline installation.

Closes: https://github.com/rook/rook/issues/6406
Signed-off-by: subhamkrai <srai@redhat.com>
2021-09-08 19:52:05 +05:30
Blaine Gardner 97075a2422 build: fix cross build run script
Fixes issues with the `build/run` tooling, notably for publishing images
where `build/run make <args>` would only result in `make` being called
without args.

Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
2021-09-01 14:11:03 -06:00