mirror of
https://github.com/replicatedhq/troubleshoot.git
synced 2026-08-27 00:37:20 +00:00
include versionNumber as spec.versionNumber to follow k8s struct standards
This commit is contained in:
@@ -30,9 +30,11 @@ const VersionFilename = "version.yaml"
|
||||
|
||||
func writeVersionFile(path string) error {
|
||||
version := troubleshootv1beta1.SupportBundleVersion{
|
||||
ApiVersion: "troubleshoot.replicated.com/v1beta1",
|
||||
Kind: "SupportBundle",
|
||||
VersionNumber: version.Version(),
|
||||
ApiVersion: "troubleshoot.replicated.com/v1beta1",
|
||||
Kind: "SupportBundle",
|
||||
Spec: troubleshootv1beta1.SupportBundleVersionSpec{
|
||||
VersionNumber: version.Version(),
|
||||
},
|
||||
}
|
||||
b, err := yaml.Marshal(version)
|
||||
if err != nil {
|
||||
|
||||
@@ -1,7 +1,11 @@
|
||||
package v1beta1
|
||||
|
||||
type SupportBundleVersion struct {
|
||||
ApiVersion string `json:"apiVersion" yaml:"apiVersion"`
|
||||
Kind string `json:"kind" yaml:"kind"`
|
||||
type SupportBundleVersionSpec struct {
|
||||
VersionNumber string `json:"versionNumber" yaml:"versionNumber"`
|
||||
}
|
||||
|
||||
type SupportBundleVersion struct {
|
||||
ApiVersion string `json:"apiVersion" yaml:"apiVersion"`
|
||||
Kind string `json:"kind" yaml:"kind"`
|
||||
Spec SupportBundleVersionSpec `json:"spec" yaml:"spec"`
|
||||
}
|
||||
|
||||
@@ -1493,6 +1493,7 @@ func (in *StorageClass) DeepCopy() *StorageClass {
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *SupportBundleVersion) DeepCopyInto(out *SupportBundleVersion) {
|
||||
*out = *in
|
||||
out.Spec = in.Spec
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SupportBundleVersion.
|
||||
@@ -1505,6 +1506,21 @@ func (in *SupportBundleVersion) DeepCopy() *SupportBundleVersion {
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *SupportBundleVersionSpec) DeepCopyInto(out *SupportBundleVersionSpec) {
|
||||
*out = *in
|
||||
}
|
||||
|
||||
// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SupportBundleVersionSpec.
|
||||
func (in *SupportBundleVersionSpec) DeepCopy() *SupportBundleVersionSpec {
|
||||
if in == nil {
|
||||
return nil
|
||||
}
|
||||
out := new(SupportBundleVersionSpec)
|
||||
in.DeepCopyInto(out)
|
||||
return out
|
||||
}
|
||||
|
||||
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
|
||||
func (in *TextAnalyze) DeepCopyInto(out *TextAnalyze) {
|
||||
*out = *in
|
||||
|
||||
Reference in New Issue
Block a user