Skip to content

Commit e9c7323

Browse files
committed
add channel entries to the packagemanifests api
Signed-off-by: Joe Lanford <[email protected]>
1 parent 6cfd86c commit e9c7323

10 files changed

+1066
-20
lines changed

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

+12-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,17 @@ 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, with their upgrade edges.
85+
Entries []ChannelEntry
86+
}
87+
88+
type ChannelEntry struct {
89+
Name string
90+
Version string
91+
Replaces string
92+
Skips []string
93+
SkipRange string
8494
}
8595

8696
// CSVDescription defines a description of a CSV

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

+12-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,17 @@ 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+
type ChannelEntry struct {
89+
Name string `json:"name"`
90+
Version string `json:"version,omitempty"`
91+
Replaces string `json:"replaces,omitempty"`
92+
Skips []string `json:"skips,omitempty"`
93+
SkipRange string `json:"skipRange,omitempty"`
8494
}
8595

8696
// CSVDescription defines a description of a CSV

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

+40
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

+28
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

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

0 commit comments

Comments
 (0)