Documentation
¶
Index ¶
- Constants
- type PluginDetailDto
- type PluginListComponentDto
- type PluginMetadataDto
- type PluginMinDto
- type PluginParentMetadataDto
- func (r *PluginParentMetadataDto) WithDescription(desc string) *PluginParentMetadataDto
- func (r *PluginParentMetadataDto) WithIcon(icon string) *PluginParentMetadataDto
- func (r *PluginParentMetadataDto) WithNameAndId(name string, id int) *PluginParentMetadataDto
- func (r *PluginParentMetadataDto) WithPluginIdentifier(identifier string) *PluginParentMetadataDto
- func (r *PluginParentMetadataDto) WithType(pluginType string) *PluginParentMetadataDto
- func (r *PluginParentMetadataDto) WithVersions(versions *PluginVersions) *PluginParentMetadataDto
- type PluginPipelineScript
- type PluginStepCondition
- type PluginStepsDto
- type PluginTagsDto
- type PluginVariableDto
- type PluginVersions
- type PluginVersionsMinDto
- type PluginsDto
- type PluginsListFilter
- type PluginsVersionDetail
- func (r *PluginsVersionDetail) SetMinimalPluginsVersionDetail(pluginVersionMetadata *repository.PluginMetadata) *PluginsVersionDetail
- func (r *PluginsVersionDetail) WithCreatedOn(createdOn time.Time) *PluginsVersionDetail
- func (r *PluginsVersionDetail) WithInputVariables(inputVariables []*PluginVariableDto) *PluginsVersionDetail
- func (r *PluginsVersionDetail) WithLastUpdatedEmail(email string) *PluginsVersionDetail
- func (r *PluginsVersionDetail) WithOutputVariables(outputVariables []*PluginVariableDto) *PluginsVersionDetail
- func (r *PluginsVersionDetail) WithTags(tags []string) *PluginsVersionDetail
- type RegistryCredentials
- type ScriptPathArgPortMapping
Constants ¶
View Source
const ( CREATEPLUGIN = 0 UPDATEPLUGIN = 1 DELETEPLUGIN = 2 CI_TYPE_PLUGIN = "CI" CD_TYPE_PLUGIN = "CD" CI_CD_TYPE_PLUGIN = "CI_CD" )
View Source
const ( NoPluginOrParentIdProvidedErr = "no value for pluginVersionIds and parentPluginIds provided in query param" NoPluginFoundForThisSearchQueryErr = "unable to find desired plugin for the query filter" )
View Source
const (
SpecialCharsRegex = ` !"#$%&'()*+,./:;<=>?@[\]^_{|}~` + "`"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PluginDetailDto ¶
type PluginDetailDto struct {
Metadata *PluginMetadataDto `json:"metadata"`
InputVariables []*PluginVariableDto `json:"inputVariables"`
OutputVariables []*PluginVariableDto `json:"outputVariables"`
}
type PluginListComponentDto ¶
type PluginListComponentDto struct {
*PluginMetadataDto
InputVariables []*PluginVariableDto `json:"inputVariables"`
OutputVariables []*PluginVariableDto `json:"outputVariables"`
}
type PluginMetadataDto ¶
type PluginMetadataDto struct {
Id int `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
Type string `json:"type,omitempty" validate:"oneof=SHARED PRESET"` // SHARED, PRESET etc
Icon string `json:"icon,omitempty"`
Tags []string `json:"tags"`
Action int `json:"action,omitempty"`
PluginStage string `json:"pluginStage,omitempty"`
PluginSteps []*PluginStepsDto `json:"pluginSteps,omitempty"`
}
func (*PluginMetadataDto) GetPluginMetadataSqlObj ¶
func (r *PluginMetadataDto) GetPluginMetadataSqlObj(userId int32) *repository.PluginMetadata
type PluginMinDto ¶
type PluginMinDto struct {
PluginName string `json:"pluginName"`
PluginVersions []*PluginVersionsMinDto `json:"pluginVersions"`
Icon string `json:"icon"`
}
type PluginParentMetadataDto ¶
type PluginParentMetadataDto struct {
Id int `json:"id"`
Name string `json:"name"`
PluginIdentifier string `json:"pluginIdentifier"`
Description string `json:"description"`
Type string `json:"type,omitempty" validate:"oneof=SHARED PRESET"`
Icon string `json:"icon,omitempty"`
Versions *PluginVersions `json:"pluginVersions"`
}
func NewPluginParentMetadataDto ¶
func NewPluginParentMetadataDto() *PluginParentMetadataDto
func (*PluginParentMetadataDto) WithDescription ¶
func (r *PluginParentMetadataDto) WithDescription(desc string) *PluginParentMetadataDto
func (*PluginParentMetadataDto) WithIcon ¶
func (r *PluginParentMetadataDto) WithIcon(icon string) *PluginParentMetadataDto
func (*PluginParentMetadataDto) WithNameAndId ¶
func (r *PluginParentMetadataDto) WithNameAndId(name string, id int) *PluginParentMetadataDto
func (*PluginParentMetadataDto) WithPluginIdentifier ¶
func (r *PluginParentMetadataDto) WithPluginIdentifier(identifier string) *PluginParentMetadataDto
func (*PluginParentMetadataDto) WithType ¶
func (r *PluginParentMetadataDto) WithType(pluginType string) *PluginParentMetadataDto
func (*PluginParentMetadataDto) WithVersions ¶
func (r *PluginParentMetadataDto) WithVersions(versions *PluginVersions) *PluginParentMetadataDto
type PluginPipelineScript ¶
type PluginPipelineScript struct {
Id int `json:"id"`
Script string `json:"script"`
StoreScriptAt string `json:"storeScriptAt"`
Type repository.ScriptType `json:"type"`
DockerfileExists bool `json:"dockerfileExists"`
MountPath string `json:"mountPath"`
MountCodeToContainer bool `json:"mountCodeToContainer"`
MountCodeToContainerPath string `json:"mountCodeToContainerPath"`
MountDirectoryFromHost bool `json:"mountDirectoryFromHost"`
ContainerImagePath string `json:"containerImagePath"`
ImagePullSecretType repository.ScriptImagePullSecretType `json:"imagePullSecretType"`
ImagePullSecret string `json:"imagePullSecret"`
Deleted bool `json:"deleted"`
PathArgPortMapping []*ScriptPathArgPortMapping `json:"pathArgPortMapping"`
}
type PluginStepCondition ¶
type PluginStepCondition struct {
Id int `json:"id"`
PluginStepId int `json:"pluginStepId"`
ConditionVariableId int `json:"conditionVariableId"` //id of variable on which condition is written
ConditionType repository.PluginStepConditionType `json:"conditionType"`
ConditionalOperator string `json:"conditionalOperator"`
ConditionalValue string `json:"conditionalValue"`
Deleted bool `json:"deleted"`
}
type PluginStepsDto ¶
type PluginStepsDto struct {
Id int `json:"id,pk"`
Name string `json:"name"`
Description string `json:"description"`
Index int `json:"index"`
StepType repository.PluginStepType `json:"stepType"`
RefPluginId int `json:"refPluginId"` //id of plugin used as reference
OutputDirectoryPath []string `json:"outputDirectoryPath"`
DependentOnStep string `json:"dependentOnStep"`
PluginStepVariable []*PluginVariableDto `json:"pluginStepVariable,omitempty"`
PluginPipelineScript *PluginPipelineScript `json:"pluginPipelineScript,omitempty"`
}
type PluginTagsDto ¶
type PluginTagsDto struct {
TagNames []string `json:"tagNames"`
}
func NewPluginTagsDto ¶
func NewPluginTagsDto() *PluginTagsDto
func (*PluginTagsDto) WithTagNames ¶
func (r *PluginTagsDto) WithTagNames(tags []string) *PluginTagsDto
type PluginVariableDto ¶
type PluginVariableDto struct {
Id int `json:"id,omitempty"`
Name string `json:"name"`
Format repository.PluginStepVariableFormatType `json:"format"`
Description string `json:"description"`
IsExposed bool `json:"isExposed"`
AllowEmptyValue bool `json:"allowEmptyValue"`
DefaultValue string `json:"defaultValue"`
Value string `json:"value,omitempty"`
VariableType repository.PluginStepVariableType `json:"variableType"`
ValueType repository.PluginStepVariableValueType `json:"valueType,omitempty"`
PreviousStepIndex int `json:"previousStepIndex,omitempty"`
VariableStepIndex int `json:"variableStepIndex"`
VariableStepIndexInPlugin int `json:"variableStepIndexInPlugin"`
ReferenceVariableName string `json:"referenceVariableName,omitempty"`
PluginStepCondition []*PluginStepCondition `json:"pluginStepCondition,omitempty"`
}
type PluginVersions ¶
type PluginVersions struct {
DetailedPluginVersionData []*PluginsVersionDetail `json:"detailedPluginVersionData"` // contains detailed data with all input and output variables
MinimalPluginVersionData []*PluginsVersionDetail `json:"minimalPluginVersionData"` // contains only few metadata
}
func NewPluginVersions ¶
func NewPluginVersions() *PluginVersions
func (*PluginVersions) WithDetailedPluginVersionData ¶
func (r *PluginVersions) WithDetailedPluginVersionData(detailedPluginVersionData []*PluginsVersionDetail) *PluginVersions
func (*PluginVersions) WithMinimalPluginVersionData ¶
func (r *PluginVersions) WithMinimalPluginVersionData(minimalPluginVersionData []*PluginsVersionDetail) *PluginVersions
type PluginVersionsMinDto ¶
type PluginsDto ¶
type PluginsDto struct {
ParentPlugins []*PluginParentMetadataDto `json:"parentPlugins"`
TotalCount int `json:"totalCount"`
}
func NewPluginsDto ¶
func NewPluginsDto() *PluginsDto
func (*PluginsDto) WithParentPlugins ¶
func (r *PluginsDto) WithParentPlugins(parentPlugins []*PluginParentMetadataDto) *PluginsDto
func (*PluginsDto) WithTotalCount ¶
func (r *PluginsDto) WithTotalCount(count int) *PluginsDto
type PluginsListFilter ¶
type PluginsListFilter struct {
Offset int
Limit int
SearchKey string
Tags []string
FetchAllVersionDetails bool
}
func NewPluginsListFilter ¶
func NewPluginsListFilter() *PluginsListFilter
func (*PluginsListFilter) WithLimit ¶
func (r *PluginsListFilter) WithLimit(limit int) *PluginsListFilter
func (*PluginsListFilter) WithOffset ¶
func (r *PluginsListFilter) WithOffset(offset int) *PluginsListFilter
func (*PluginsListFilter) WithSearchKey ¶
func (r *PluginsListFilter) WithSearchKey(searchKey string) *PluginsListFilter
func (*PluginsListFilter) WithTags ¶
func (r *PluginsListFilter) WithTags(tags []string) *PluginsListFilter
type PluginsVersionDetail ¶
type PluginsVersionDetail struct {
*PluginMetadataDto
InputVariables []*PluginVariableDto `json:"inputVariables"`
OutputVariables []*PluginVariableDto `json:"outputVariables"`
DocLink string `json:"docLink"`
Version string `json:"pluginVersion"`
IsLatest bool `json:"isLatest"`
UpdatedBy string `json:"updatedBy"`
CreatedOn time.Time `json:"-"`
}
func NewPluginsVersionDetail ¶
func NewPluginsVersionDetail() *PluginsVersionDetail
func (*PluginsVersionDetail) SetMinimalPluginsVersionDetail ¶
func (r *PluginsVersionDetail) SetMinimalPluginsVersionDetail(pluginVersionMetadata *repository.PluginMetadata) *PluginsVersionDetail
SetMinimalPluginsVersionDetail sets and return PluginsVersionDetail obj, returns lightweight obj e.g. excluding input and output variables
func (*PluginsVersionDetail) WithCreatedOn ¶
func (r *PluginsVersionDetail) WithCreatedOn(createdOn time.Time) *PluginsVersionDetail
func (*PluginsVersionDetail) WithInputVariables ¶
func (r *PluginsVersionDetail) WithInputVariables(inputVariables []*PluginVariableDto) *PluginsVersionDetail
func (*PluginsVersionDetail) WithLastUpdatedEmail ¶
func (r *PluginsVersionDetail) WithLastUpdatedEmail(email string) *PluginsVersionDetail
func (*PluginsVersionDetail) WithOutputVariables ¶
func (r *PluginsVersionDetail) WithOutputVariables(outputVariables []*PluginVariableDto) *PluginsVersionDetail
func (*PluginsVersionDetail) WithTags ¶
func (r *PluginsVersionDetail) WithTags(tags []string) *PluginsVersionDetail
type RegistryCredentials ¶
type RegistryCredentials struct {
RegistryType string `json:"registryType" validate:"required"`
RegistryURL string `json:"registryURL"`
Username string `json:"username"`
Password string `json:"password"`
AWSAccessKeyId string `json:"awsAccessKeyId,omitempty"`
AWSSecretAccessKey string `json:"awsSecretAccessKey,omitempty"`
AWSRegion string `json:"awsRegion,omitempty"`
}
type ScriptPathArgPortMapping ¶
type ScriptPathArgPortMapping struct {
Id int `json:"id"`
TypeOfMapping repository.ScriptMappingType `json:"typeOfMapping"`
FilePathOnDisk string `json:"filePathOnDisk"`
FilePathOnContainer string `json:"filePathOnContainer"`
Command string `json:"command"`
Args []string `json:"args"`
PortOnLocal int `json:"portOnLocal"`
PortOnContainer int `json:"portOnContainer"`
ScriptId int `json:"scriptId"`
}
Click to show internal directories.
Click to hide internal directories.