*: generate k8s manifest#72
Merged
fanminshi merged 3 commits intooperator-framework:masterfrom Mar 1, 2018
fanminshi:gen_manifest
Merged
*: generate k8s manifest#72fanminshi merged 3 commits intooperator-framework:masterfrom fanminshi:gen_manifest
fanminshi merged 3 commits intooperator-framework:masterfrom
fanminshi:gen_manifest
Conversation
Contributor
Author
|
Manual Test: |
Contributor
Author
|
cc/ @hasbro17 |
Contributor
|
The CRD output above seems incorrect. For apiVersion: apiextensions.k8s.io/v1beta1
kind: CustomResourceDefinition
metadata:
# name is of the form <plural>.<group>
name: appservices.app.example.com
spec:
group: app.example.com
names:
# kind is normally the CamelCased singular type
kind: AppService
listKind: AppServiceList
plural: appservices
singular: appservice
scope: Namespaced
version: v1alpha1 |
Contributor
Author
|
@hasbro17 good catch. |
Contributor
Author
|
latest output: |
Contributor
Author
|
all fixed PTAL cc/ @hasbro17 |
hasbro17
reviewed
Mar 1, 2018
| "os" | ||
| "os/exec" | ||
|
|
||
| "github.com/coreos/operator-sdk/pkg/generator" |
Contributor
Author
|
All Fixed. CC/ @hasbro17 |
hasbro17
reviewed
Mar 1, 2018
| t := template.New("deploy/operator.yaml") | ||
| t, err := t.Parse(operatorYamlTmpl) | ||
| if err != nil { | ||
| return err |
Contributor
There was a problem hiding this comment.
Probably best to wrap the error
return fmt.Errorf("failed to parse operator yaml template: %v", err)
hasbro17
reviewed
Mar 1, 2018
|
|
||
| // renderOperatorYaml generates deploy/operator.yaml. | ||
| func renderOperatorYaml(w io.Writer, kind, apiVersion, projectName, image string) error { | ||
| t := template.New("deploy/operator.yaml") |
Contributor
There was a problem hiding this comment.
Make the file name deploy/operator.yaml a constant.
Contributor
|
LGTM after nits |
Contributor
Author
|
fixed! merging! |
m1kola
pushed a commit
to m1kola/operator-sdk
that referenced
this pull request
Jun 7, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
this pr allows operator-sdk build to create deploy/operator.yaml base on metadata in config/config.yaml and the input image.