Skip to content

Commit e7c2de3

Browse files
authored
add channel entries to the packagemanifests api (#2893)
Signed-off-by: Joe Lanford <[email protected]> Signed-off-by: Joe Lanford <[email protected]>
1 parent 80b914d commit e7c2de3

10 files changed

+800
-20
lines changed

pkg/package-server/apis/operators/packagemanifest_types.go

+13-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
package operators
22

33
import (
4-
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
5-
64
"github.com/operator-framework/api/pkg/lib/version"
75
operatorv1alpha1 "github.com/operator-framework/api/pkg/operators/v1alpha1"
6+
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
87
)
98

109
// PackageManifestList is a list of PackageManifest objects.
@@ -81,6 +80,18 @@ type PackageChannel struct {
8180

8281
// CurrentCSVSpec holds the spec of the current CSV
8382
CurrentCSVDesc CSVDescription
83+
84+
// Entries lists all CSVs in the channel.
85+
Entries []ChannelEntry
86+
}
87+
88+
// ChannelEntry defines a member of a package channel.
89+
type ChannelEntry struct {
90+
// Name is the name of the bundle for this entry.
91+
Name string
92+
93+
// Version is the version of the bundle for this entry.
94+
Version string
8495
}
8596

8697
// CSVDescription defines a description of a CSV

pkg/package-server/apis/operators/v1/packagemanifest_types.go

+13-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
package v1
22

33
import (
4-
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
5-
64
"github.com/operator-framework/api/pkg/lib/version"
75
operatorv1alpha1 "github.com/operator-framework/api/pkg/operators/v1alpha1"
6+
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
87
)
98

109
// PackageManifestList is a list of PackageManifest objects.
@@ -81,6 +80,18 @@ type PackageChannel struct {
8180

8281
// CurrentCSVSpec holds the spec of the current CSV
8382
CurrentCSVDesc CSVDescription `json:"currentCSVDesc,omitempty"`
83+
84+
// Entries lists all CSVs in the channel, with their upgrade edges.
85+
Entries []ChannelEntry `json:"entries"`
86+
}
87+
88+
// ChannelEntry defines a member of a package channel.
89+
type ChannelEntry struct {
90+
// Name is the name of the bundle for this entry.
91+
Name string `json:"name"`
92+
93+
// Version is the version of the bundle for this entry.
94+
Version string `json:"version,omitempty"`
8495
}
8596

8697
// CSVDescription defines a description of a CSV

pkg/package-server/apis/operators/v1/zz_generated.conversion.go

+34
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/package-server/apis/operators/v1/zz_generated.deepcopy.go

+21
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/package-server/apis/operators/zz_generated.deepcopy.go

+21
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)