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>
The appVersion should be set to the version of the application. Since the helm
charts are built by Rook in the same release version as Rook itself, the
version and appVersion values will be the same.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
Create a Helm library chart to share content between the Operator Helm
chart (rook-ceph) and the CephCluster (etc.) Helm chart
(rook-ceph-cluster).
This will ensure that when resources related to the CephCluster change,
notably RBAC resources, they will change for both charts.
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
Remove all make-related references to NFS and Cassandra. This is limited
purely to make targets. Leave CRD and codegen script references to be
removed in a different commit.
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
deepcopy-gen appends a header starting with `// +build` which makes
gofmt to complain in Go 1.17 so until this is fixed in
https://github.com/kubernetes/gengo/pull/210 let's skip those files for
formatting.
Signed-off-by: Sébastien Han <seb@redhat.com>
The CI now runs the build test against Golang 1.16 and 1.17.
So 1.17 is been added as a supported version.
Signed-off-by: Sébastien Han <seb@redhat.com>
Print the Go version when running any Go build target. This can be
helpful in making sure that we are building with the Go version we want
and expect.
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
If a user were to `make build` Rook, and after the Ceph CSV was
generated and before make had finished, the Rook repo would be left with
changes caused by the build modifying files temporarily in-place.
All CSV template generation in the Ceph makefile is now self-contained
and can be configured to operate outside of the main repo so that files
are not modified in-place.
In-place modification of files was also incorrect. On Mac some files
with `-e` trailing were left, and in-place backups were also present in
the form `<filename>''`. Therefore, also fix the generation to fix
in-place modifications.
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
Adds rook-ceph-cluster chart to chart build, add tests.
Pulled out some common functionality between the Helm and non-Helm installers
Signed-off-by: Henry Zhang <me@henry.dev>
We generate vendor directory in building process. It doesn't reduce
build time. In addition, we have encountered some vendoring-related
problems. So let's stop vendoring.
Signed-off-by: Satoru Takeuchi <satoru.takeuchi@gmail.com>
Introducing a small action on MacOS to help us catch errors with various
'make' command on OSX, most notably 'sed' versus 'gnu-sed'.
Signed-off-by: Sébastien Han <seb@redhat.com>
Dependencies for `make go.test` have to run in order, so call them
explicitly from the target rather than allowing them to be done in
parallel if `make -j` flag is used.
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
CI fails on builds warning with the warning below
[2021-04-15T14:15:28.461Z] go: inconsistent vendoring in /home/rook/go/src/github.com/rook/rook:
[2021-04-15T14:15:28.461Z] github.com/jstemmer/go-junit-report@v0.9.1: is explicitly required in go.mod, but not marked as explicit in vendor/modules.txt
Fix this by running `go mod vendor` before each build.
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
With the release of go 1.16, we update the tools. The -i flag is
now deprecated, no longer necessary for building in a private directory.
The go modules are cleaned up at the same time.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
CSV generation now requires versions of yq and operator-sdk that are
downloaded by the makefiles. Previously Ceph image creation used
makefile versions but `make csv-ceph` used versions present on the
system.
`sed -i 's///g' $FILE` doesn't work on Unix/Mac.
`sed -i'' -e 's///g' $FILE` is portable.
Signed-off-by: Blaine Gardner <blaine.gardner@redhat.com>
The YugabyteDB team has decided to move support of their operator
to a new repo at https://github.com/yugabyte/yugabyte-operator.
The operator in Rook is no longer needed. Further usage of
the YugabyteDB operator is recommended at the new location.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
shasum is not always available and sha256sum seems to exist more often
since it's part of coreutils where sha256sum comes with perl.
Signed-off-by: Sébastien Han <seb@redhat.com>
The cockroachDB operator has not had community support in Rook.
Therefore, the time has come to deprecate and remove it.
If the sources are still needed, there is always git history.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
This updates the chart to make use of helm3 which has been released
for some time, and also permits CRDs to be installed pror to other objects
allowing the chart to be deployed at the same time as CRs for rook objects.
Co-authored-by: Pete Birley <pete@port.direct>
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
Found by running the following command:
codespell -S .git,*.png,*.jpg -L \
aks,keyserver,atleast,dne,ser,ist,files\',ba,dum,iam,te -f -H
Signed-off-by: Mateusz Gozdek <mgozdekof@gmail.com>
To be able to switch to helm v3, helm itself needs to be downloaded from
get.helm.sh. The old location from googleapis.com will only contain
helm v2 binaries. See [1].
[1] https://helm.sh/blog/get-helm-sh/
Signed-off-by: Thomas Bechtold <tbechtold@suse.com>
Currently, Helm v2.5.1 is used, but this version is released in 2017
and a little outdated.
To use the latest version of helm v2.x.x would be beneficial
as we can use more useful Helm commands like `helm template`.
This commit updates Helm version and stop using `helm lint`
with `--strict` option because Helm v2.16.7 does not allow
to use undefined values in values.yaml and
the Helm upstream is now stopping using the `--strict` option.
Signed-off-by: binoue <banji-inoue@cybozu.co.jp>
The longhaul tests have not been run for a very long time,
on the order of two years. The intention is to get them running
again, but until then it is better to purge the obsolete sources
than to attempt to keep them building. We'll need to rewrite them
when they are restored.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
Current Rook code uses go dep 0.5.0 and separates handling
for Arm and x86. It's because there's no dep 0.5.0 binary
for arm64.Dep has updated to 0.5.4 and supports arm64. Rook
code can be simplified by upgrading dep to fix gaps of Arm
and x86.
Change-Id: Id91a993ca059461faa8a83065c93dadc7cdffeb2
Signed-off-by: Haichao Li <haichao.li@arm.com>
The minio operator has not had community support nor
any updates since being added to Rook. Support is being
removed from Rook due to this lack of community interest.
Signed-off-by: Travis Nielsen <tnielsen@redhat.com>
Remove %% around VERSION in charts yaml, so helm can process it.
Otherwise helm complains:
"unmarshal vendor values: yaml: line 7: found character that cannot start any token"
Signed-off-by: Dinar Valeev <k0da@opensuse.org>
In order to not leave any modified file after release, lets put
chart tree aside and run sed logic on it.
Signed-off-by: Dinar Valeev <k0da@opensuse.org>