Skip to content
This repository was archived by the owner on Jan 23, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions api/v1alpha1/exporter_helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import (

cpb "github.com/jumpstarter-dev/jumpstarter-controller/internal/protocol/jumpstarter/client/v1"
"github.com/jumpstarter-dev/jumpstarter-controller/internal/service/utils"
"k8s.io/apimachinery/pkg/api/meta"
kclient "sigs.k8s.io/controller-runtime/pkg/client"
)

Expand All @@ -23,9 +24,13 @@ func (e *Exporter) Usernames(prefix string) []string {
}

func (e *Exporter) ToProtobuf() *cpb.Exporter {
// get online status from conditions
isOnline := meta.IsStatusConditionTrue(e.Status.Conditions, string(ExporterConditionTypeOnline))

return &cpb.Exporter{
Name: utils.UnparseExporterIdentifier(kclient.ObjectKeyFromObject(e)),
Labels: e.Labels,
Online: isOnline,
Comment thread
mangelajo marked this conversation as resolved.
}
}

Expand Down
4 changes: 2 additions & 2 deletions api/v1alpha1/exporter_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ type ExporterStatus struct {
type ExporterConditionType string

const (
ExporterConditionTypeRegistered LeaseConditionType = "Registered"
ExporterConditionTypeOnline LeaseConditionType = "Online"
ExporterConditionTypeRegistered ExporterConditionType = "Registered"
ExporterConditionTypeOnline ExporterConditionType = "Online"
)

// +kubebuilder:object:root=true
Expand Down
339 changes: 90 additions & 249 deletions internal/protocol/jumpstarter/client/v1/client.pb.go

Large diffs are not rendered by default.

26 changes: 21 additions & 5 deletions internal/protocol/jumpstarter/client/v1/client.pb.gw.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading
Loading