|
| 1 | +// Copyright 2025 The PipeCD Authors. |
| 2 | +// |
| 3 | +// Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | +// you may not use this file except in compliance with the License. |
| 5 | +// You may obtain a copy of the License at |
| 6 | +// |
| 7 | +// http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | +// |
| 9 | +// Unless required by applicable law or agreed to in writing, software |
| 10 | +// distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | +// See the License for the specific language governing permissions and |
| 13 | +// limitations under the License. |
| 14 | + |
| 15 | +package main |
| 16 | + |
| 17 | +import ( |
| 18 | + "context" |
| 19 | + |
| 20 | + "github.com/pipe-cd/pipecd/pkg/plugin/sdk" |
| 21 | +) |
| 22 | + |
| 23 | +type plugin struct{} |
| 24 | + |
| 25 | +type config struct{} |
| 26 | + |
| 27 | +// Name implements sdk.Plugin. |
| 28 | +func (p *plugin) Name() string { |
| 29 | + return "kubernetes_multicluster" |
| 30 | +} |
| 31 | + |
| 32 | +// Version implements sdk.Plugin. |
| 33 | +func (p *plugin) Version() string { |
| 34 | + return "0.0.1" |
| 35 | +} |
| 36 | + |
| 37 | +// BuildPipelineSyncStages implements sdk.PipelineSyncPlugin. |
| 38 | +func (p *plugin) BuildPipelineSyncStages(context.Context, *config, *sdk.BuildPipelineSyncStagesInput) (*sdk.BuildPipelineSyncStagesResponse, error) { |
| 39 | + return &sdk.BuildPipelineSyncStagesResponse{}, nil |
| 40 | +} |
| 41 | + |
| 42 | +// ExecuteStage implements sdk.PipelineSyncPlugin. |
| 43 | +func (p *plugin) ExecuteStage(context.Context, *config, sdk.DeployTargetsNone, *sdk.ExecuteStageInput) (*sdk.ExecuteStageResponse, error) { |
| 44 | + return &sdk.ExecuteStageResponse{}, nil |
| 45 | +} |
| 46 | + |
| 47 | +// FetchDefinedStages implements sdk.PipelineSyncPlugin. |
| 48 | +func (p *plugin) FetchDefinedStages() []string { |
| 49 | + return []string{"K8S_SYNC"} |
| 50 | +} |
0 commit comments