radanalyticsio / spark-operator

Operator for managing the Spark clusters on Kubernetes and OpenShift.
Apache License 2.0
157 stars 61 forks source link

Very Quick Start Fails #341

Open alex-treebeard opened 3 years ago

alex-treebeard commented 3 years ago

Description:

I'm new to operators, but it seems the Very Quick Start setup guide is missing the CRD definition installation?

Steps to reproduce:

  1.     ➜ kubectl apply -f http://bit.ly/sparkop
        serviceaccount/spark-operator created
        Warning: rbac.authorization.k8s.io/v1beta1 ClusterRoleBinding is deprecated in v1.17+, unavailable in v1.22+; use rbac.authorization.k8s.io/v1 ClusterRoleBinding
        clusterrolebinding.rbac.authorization.k8s.io/spark-operator-edit-resources created
        deployment.apps/spark-operator created
  2.     ➜ cat <<EOF | kubectl apply -f -
        apiVersion: v1
        kind: SparkCluster
        metadata:
          name: my-cluster
        spec:
          worker:
            instances: "2"
        EOF
        error: unable to recognize "STDIN": no matches for kind "SparkCluster" in version "v1"
jkremser commented 3 years ago

Operator creates the CRDs during its startup, so there is no need to create them. It looks like there is a typo in the readme. It the apiVersion should be radanalytics.io/v1 as in here https://github.com/radanalyticsio/spark-operator/blob/master/examples/cluster.yaml