diff --git a/cmd/uncloud/caddy/deploy.go b/cmd/uncloud/caddy/deploy.go index 3ecd76a8..9adfaa62 100644 --- a/cmd/uncloud/caddy/deploy.go +++ b/cmd/uncloud/caddy/deploy.go @@ -14,7 +14,6 @@ import ( "github.com/psviderski/uncloud/internal/machine/api/pb" "github.com/psviderski/uncloud/pkg/api" "github.com/psviderski/uncloud/pkg/client" - "github.com/psviderski/uncloud/pkg/client/deploy" "github.com/spf13/cobra" ) @@ -197,12 +196,3 @@ func UpdateDomainRecords(ctx context.Context, clusterClient *client.Client, prog return nil } - -func machineFilter(machines []string) deploy.MachineFilter { - if len(machines) == 0 { - return nil - } - return func(m *pb.MachineInfo) bool { - return slices.Contains(machines, m.Name) - } -} diff --git a/pkg/client/deploy/deploy.go b/pkg/client/deploy/deploy.go index b96f8746..d9f1b99e 100644 --- a/pkg/client/deploy/deploy.go +++ b/pkg/client/deploy/deploy.go @@ -5,7 +5,6 @@ import ( "errors" "fmt" - "github.com/psviderski/uncloud/internal/machine/api/pb" "github.com/psviderski/uncloud/pkg/api" ) @@ -34,12 +33,6 @@ type Plan struct { SequenceOperation } -// MachineFilter determines which machines participate in a deployment operation by returning true for -// machines that should be included. -type MachineFilter func(m *pb.MachineInfo) bool - -var ErrNoMatchingMachines = errors.New("no machines match the filter") - // NewDeployment creates a new deployment for the given service specification. // If strategy is nil, a default RollingStrategy will be used. func NewDeployment(cli Client, spec api.ServiceSpec, strategy Strategy) *Deployment {