mayadata-io / mayadata-io/d-operators

chore: generate custom resource definitions (CRDs)

Open
#84 1 comment 0 reactions 1 assignee View on GitHub

@amitbhatt818 is already working on this.

Since Jun 30, 2020.

  • #91 by @amitbhatt818 — closed without merging
backlog build chore on hold
Dominant language
Go
Stars
10
Forks
6
PR merge metrics
No merged PRs in 30d

Description

Refer - https://github.com/kubernetes-sigs/kubebuilder/tree/master/testdata/project-v3
Refer - https://github.com/jetstack/cert-manager

  • This issue is for automatically generate crds using types.go file. I tried to use controller-gen tool for generating the crds. But I faced multiple issues while generating the files.

    • There were some entity in our types.go (float64, InterfaceType)which is unsupported in controller-gen and because of that we are not able to perform action completely.
  • Error msg:
 Makefile:30: target 'Fetching' given more than once in the same rule
go run ./vendor/sigs.k8s.io/controller-tools/cmd/controller-gen/main.go "crd:trivialVersions=true" paths="./..." output:crd:artifacts:config=manifests/crd/bases
-: found packages types (apply.go) and v1alpha1 (doc.go) in /home/amit-bhatt/go/src/mayadata-io/d-operators/api/v1alpha1
/home/amit-bhatt/go/src/mayadata-io/d-operators/api/v1alpha1/job.go:109:22: unsupported type "float64"
/home/amit-bhatt/go/src/mayadata-io/d-operators/api/v1alpha1/job.go:118:29: unsupported type "float64"
/home/amit-bhatt/go/src/mayadata-io/d-operators/api/v1alpha1/job.go:119:29: unsupported type "float64"
/home/amit-bhatt/go/src/mayadata-io/d-operators/api/v1alpha1/patch_check.go:108:8: unsupported AST kind *ast.InterfaceType
/home/amit-bhatt/go/src/mayadata-io/d-operators/api/v1alpha1/task.go:95:24: unsupported type "float64"
Error: not all generators ran successfully
run `controller-gen crd:trivialVersions=true paths=./... output:crd:artifacts:config=manifests/crd/bases -w` to see all available markers, or `controller-gen crd:trivialVersions=true paths=./... output:crd:artifacts:config=manifests/crd/bases -h` for usage
exit status 1
make: *** [Makefile:33: manifests] Error 1     
    ```

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.