Documentation ¶
Index ¶
- Constants
- func GetConfFileForService(confFiles []string, serviceName string) string
- type CargoTomlConfig
- type DotNetCoreDockerfileGenerator
- func (t *DotNetCoreDockerfileGenerator) DirectoryDetect(dir string) (services map[string][]transformertypes.Artifact, err error)
- func (t *DotNetCoreDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
- func (t *DotNetCoreDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) error
- func (t *DotNetCoreDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, ...) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
- func (t *DotNetCoreDockerfileGenerator) TransformArtifact(newArtifact transformertypes.Artifact, ...) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
- type DotNetCoreDockerfileYamlConfig
- type DotNetCoreTemplateConfig
- type GlobalParameters
- type GolangDockerfileGenerator
- func (t *GolangDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
- func (t *GolangDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
- func (t *GolangDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
- func (t *GolangDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, ...) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
- type GolangDockerfileYamlConfig
- type GolangTemplateConfig
- type GolangVersionsMapping
- type GolangVersionsMappingSpec
- type LaunchProfile
- type LaunchSettings
- type NodeVersionsMapping
- type NodeVersionsMappingSpec
- type NodejsDockerfileGenerator
- func (t *NodejsDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
- func (t *NodejsDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
- func (t *NodejsDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) error
- func (t *NodejsDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, ...) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
- type NodejsDockerfileYamlConfig
- type NodejsTemplateConfig
- type PHPDockerfileGenerator
- func (t *PHPDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
- func (t *PHPDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
- func (t *PHPDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
- func (t *PHPDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, ...) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
- type PackageInfo
- type PackageJSON
- type PhpTemplateConfig
- type PropertyGroup
- type PublishProfile
- type PythonConfig
- type PythonDockerfileGenerator
- func (t *PythonDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
- func (t *PythonDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
- func (t *PythonDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
- func (t *PythonDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, ...) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
- type PythonTemplateConfig
- type RocketTomlConfig
- type RubyDockerfileGenerator
- func (t *RubyDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
- func (t *RubyDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
- func (t *RubyDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
- func (t *RubyDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, ...) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
- type RubyTemplateConfig
- type RustDockerfileGenerator
- func (t *RustDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
- func (t *RustDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
- func (t *RustDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
- func (t *RustDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, ...) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
- type RustTemplateConfig
Constants ¶
const ( // GolangModFilePathType points to the go.mod file path GolangModFilePathType transformertypes.PathType = "GoModFilePath" // GolangVersionsMappingKind defines kind of GolangVersionMappingKind GolangVersionsMappingKind types.Kind = "GolangVersionsMapping" )
const ( //RequirementsTxtPathType points to the requirements.txt file if it's present RequirementsTxtPathType transformertypes.PathType = "RequirementsTxtPathType" // PythonServiceConfigType points to python config PythonServiceConfigType transformertypes.ConfigType = "PythonConfig" // MainPythonFilesPathType points to the .py files path which contain main function MainPythonFilesPathType transformertypes.PathType = "MainPythonFilesPathType" // PythonFilesPathType points to the .py files path PythonFilesPathType transformertypes.PathType = "PythonFilesPathType" )
const ( // NodeVersionsMappingKind defines kind of NodeVersionMappingKind NodeVersionsMappingKind types.Kind = "NodeVersionsMapping" )
Variables ¶
This section is empty.
Functions ¶
func GetConfFileForService ¶
GetConfFileForService returns ports used by a service
Types ¶
type CargoTomlConfig ¶
type CargoTomlConfig struct {
Package PackageInfo
}
CargoTomlConfig implements Cargo.toml config interface
type DotNetCoreDockerfileGenerator ¶
type DotNetCoreDockerfileGenerator struct { Config transformertypes.Transformer Env *environment.Environment DotNetCoreConfig *DotNetCoreDockerfileYamlConfig Spec NodeVersionsMappingSpec SortedVersions []string }
DotNetCoreDockerfileGenerator implements the Transformer interface
func (*DotNetCoreDockerfileGenerator) DirectoryDetect ¶
func (t *DotNetCoreDockerfileGenerator) DirectoryDetect(dir string) (services map[string][]transformertypes.Artifact, err error)
DirectoryDetect runs detect in each sub directory
func (*DotNetCoreDockerfileGenerator) GetConfig ¶
func (t *DotNetCoreDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
GetConfig returns the transformer config
func (*DotNetCoreDockerfileGenerator) Init ¶
func (t *DotNetCoreDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) error
Init Initializes the transformer
func (*DotNetCoreDockerfileGenerator) Transform ¶
func (t *DotNetCoreDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, oldArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
Transform transforms the artifacts
func (*DotNetCoreDockerfileGenerator) TransformArtifact ¶ added in v0.3.3
func (t *DotNetCoreDockerfileGenerator) TransformArtifact(newArtifact transformertypes.Artifact, oldArtifacts []transformertypes.Artifact, dotNetConfig artifacts.DotNetConfig) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
TransformArtifact transforms a single artifact
type DotNetCoreDockerfileYamlConfig ¶
type DotNetCoreDockerfileYamlConfig struct { DefaultDotNetCoreVersion string `yaml:"defaultDotNetCoreVersion"` NodejsDockerfileYamlConfig }
DotNetCoreDockerfileYamlConfig represents the configuration of the DotNetCore dockerfile
type DotNetCoreTemplateConfig ¶
type DotNetCoreTemplateConfig struct { IncludeBuildStage bool BuildStageImageTag string BuildContainerName string IsNodeJSProject bool PublishProfilePath string IncludeRunStage bool RunStageImageTag string Ports []int32 EntryPointPath string CopyFrom string EnvVariables map[string]string NodeVersion string NodeVersionProperties map[string]string PackageManager string }
DotNetCoreTemplateConfig implements DotNetCore config interface
type GlobalParameters ¶
GlobalParameters implements global properties in Rocket.toml
type GolangDockerfileGenerator ¶
type GolangDockerfileGenerator struct { Config transformertypes.Transformer Env *environment.Environment GolangConfig *GolangDockerfileYamlConfig Spec GolangVersionsMappingSpec }
GolangDockerfileGenerator implements the Transformer interface
func (*GolangDockerfileGenerator) DirectoryDetect ¶
func (t *GolangDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
DirectoryDetect runs detect in each sub directory
func (*GolangDockerfileGenerator) GetConfig ¶
func (t *GolangDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
GetConfig returns the transformer config
func (*GolangDockerfileGenerator) Init ¶
func (t *GolangDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
Init Initializes the transformer
func (*GolangDockerfileGenerator) Transform ¶
func (t *GolangDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, alreadySeenArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
Transform transforms the artifacts
type GolangDockerfileYamlConfig ¶
type GolangDockerfileYamlConfig struct {
DefaultGoVersion string `yaml:"defaultGoVersion"`
}
GolangDockerfileYamlConfig represents the configuration of the Golang dockerfile
type GolangTemplateConfig ¶
GolangTemplateConfig implements Golang config interface
type GolangVersionsMapping ¶ added in v0.3.6
type GolangVersionsMapping struct { types.TypeMeta `yaml:",inline"` types.ObjectMeta `yaml:"metadata,omitempty"` Spec GolangVersionsMappingSpec `yaml:"spec,omitempty"` }
GolangVersionsMapping stores the Go versions mapping
type GolangVersionsMappingSpec ¶ added in v0.3.6
type GolangVersionsMappingSpec struct { DisableSort bool `yaml:"disableSort"` GolangVersions []map[string]string `yaml:"golangVersions"` }
GolangVersionsMappingSpec stores the Go version spec
func LoadGolangVersionMappingsFile ¶ added in v0.3.6
func LoadGolangVersionMappingsFile(mappingFilePath string) (GolangVersionsMappingSpec, error)
LoadGolangVersionMappingsFile loads the Golang version mappings file
type LaunchProfile ¶
type LaunchProfile struct { CommandName string `json:"CommandName"` LaunchBrowser bool `json:"launchBrowser"` ApplicationURL string `json:"applicationUrl"` EnvironmentVariables map[string]string `json:"environmentVariables"` }
LaunchProfile implements launch profile properties
type LaunchSettings ¶
type LaunchSettings struct {
Profiles map[string]LaunchProfile `json:"profiles"`
}
LaunchSettings is to load the launchSettings.json properties
type NodeVersionsMapping ¶ added in v0.3.3
type NodeVersionsMapping struct { types.TypeMeta `yaml:",inline"` types.ObjectMeta `yaml:"metadata,omitempty"` Spec NodeVersionsMappingSpec `yaml:"spec,omitempty"` }
NodeVersionsMapping stores the Node versions mapping
type NodeVersionsMappingSpec ¶ added in v0.3.3
type NodeVersionsMappingSpec struct { DisableSort bool `yaml:"disableSort"` NodeVersions []map[string]string `yaml:"nodeVersions"` }
NodeVersionsMappingSpec stores the Node version spec
func LoadNodeVersionMappingsFile ¶ added in v0.3.3
func LoadNodeVersionMappingsFile(mappingFilePath string) (NodeVersionsMappingSpec, error)
LoadNodeVersionMappingsFile loads the node version mappings file
type NodejsDockerfileGenerator ¶
type NodejsDockerfileGenerator struct { Config transformertypes.Transformer Env *environment.Environment NodejsConfig *NodejsDockerfileYamlConfig Spec NodeVersionsMappingSpec }
NodejsDockerfileGenerator implements the Transformer interface
func (*NodejsDockerfileGenerator) DirectoryDetect ¶
func (t *NodejsDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
DirectoryDetect runs detect in each sub directory
func (*NodejsDockerfileGenerator) GetConfig ¶
func (t *NodejsDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
GetConfig returns the transformer config
func (*NodejsDockerfileGenerator) Init ¶
func (t *NodejsDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) error
Init Initializes the transformer
func (*NodejsDockerfileGenerator) Transform ¶
func (t *NodejsDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, alreadySeenArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
Transform transforms the artifacts
type NodejsDockerfileYamlConfig ¶
type NodejsDockerfileYamlConfig struct { DefaultNodejsVersion string `yaml:"defaultNodejsVersion"` DefaultPackageManager string `yaml:"defaultPackageManager"` }
NodejsDockerfileYamlConfig represents the configuration of the Nodejs dockerfile
type NodejsTemplateConfig ¶
type NodejsTemplateConfig struct { Port int32 Build bool NodeVersion string NodeImageTag string NodeMajorVersion string NodeVersionProperties map[string]string PackageManager string }
NodejsTemplateConfig implements Nodejs config interface
type PHPDockerfileGenerator ¶
type PHPDockerfileGenerator struct { Config transformertypes.Transformer Env *environment.Environment }
PHPDockerfileGenerator implements the Transformer interface
func (*PHPDockerfileGenerator) DirectoryDetect ¶
func (t *PHPDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
DirectoryDetect runs detect in each sub directory
func (*PHPDockerfileGenerator) GetConfig ¶
func (t *PHPDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
GetConfig returns the transformer config
func (*PHPDockerfileGenerator) Init ¶
func (t *PHPDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
Init Initializes the transformer
func (*PHPDockerfileGenerator) Transform ¶
func (t *PHPDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, alreadySeenArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
Transform transforms the artifacts
type PackageInfo ¶
PackageInfo implements package properties
type PackageJSON ¶
type PackageJSON struct { Private bool `json:"private"` Name string `json:"name"` Version string `json:"version"` Description string `json:"description"` Homepage string `json:"homepage"` License string `json:"license"` Main string `json:"main"` PackageManager string `json:"packageManager,omitempty"` Keywords []string `json:"keywords,omitempty"` Files []string `json:"files,omitempty"` Os []string `json:"os,omitempty"` CPU []string `json:"cpu,omitempty"` Scripts map[string]string `json:"scripts,omitempty"` Engines map[string]string `json:"engines,omitempty"` Dependencies map[string]string `json:"dependencies,omitempty"` }
PackageJSON represents NodeJS package.json
type PhpTemplateConfig ¶
PhpTemplateConfig implements Php config interface
type PropertyGroup ¶
type PropertyGroup struct { XMLName xml.Name `xml:"PropertyGroup"` PublishUrl string `xml:"PublishUrl"` PublishUrlS string `xml:"publishUrl"` }
PropertyGroup has publish properties of the project
type PublishProfile ¶
type PublishProfile struct { XMLName xml.Name `xml:"Project"` PropertyGroup *PropertyGroup `xml:"PropertyGroup"` }
PublishProfile defines the publish profile
type PythonConfig ¶
type PythonConfig struct {
IsDjango bool `json:"IsDjango" yaml:"IsDjango"`
}
PythonConfig implements python config interface
type PythonDockerfileGenerator ¶
type PythonDockerfileGenerator struct { Config transformertypes.Transformer Env *environment.Environment }
PythonDockerfileGenerator implements the Transformer interface
func (*PythonDockerfileGenerator) DirectoryDetect ¶
func (t *PythonDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
DirectoryDetect runs detect in each sub directory
func (*PythonDockerfileGenerator) GetConfig ¶
func (t *PythonDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
GetConfig returns the transformer config
func (*PythonDockerfileGenerator) Init ¶
func (t *PythonDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
Init Initializes the transformer
func (*PythonDockerfileGenerator) Transform ¶
func (t *PythonDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, alreadySeenArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
Transform transforms the artifacts
type PythonTemplateConfig ¶
type PythonTemplateConfig struct { AppName string Port int32 StartingScriptRelPath string RequirementsTxt string IsDjango bool }
PythonTemplateConfig implements python config interface
type RocketTomlConfig ¶
type RocketTomlConfig struct {
Global GlobalParameters
}
RocketTomlConfig implements Rocket.toml config interface
type RubyDockerfileGenerator ¶
type RubyDockerfileGenerator struct { Config transformertypes.Transformer Env *environment.Environment }
RubyDockerfileGenerator implements the Transformer interface
func (*RubyDockerfileGenerator) DirectoryDetect ¶
func (t *RubyDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
DirectoryDetect runs detect in each sub directory
func (*RubyDockerfileGenerator) GetConfig ¶
func (t *RubyDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
GetConfig returns the transformer config
func (*RubyDockerfileGenerator) Init ¶
func (t *RubyDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
Init Initializes the transformer
func (*RubyDockerfileGenerator) Transform ¶
func (t *RubyDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, alreadySeenArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
Transform transforms the artifacts
type RubyTemplateConfig ¶
RubyTemplateConfig implements Ruby config interface
type RustDockerfileGenerator ¶
type RustDockerfileGenerator struct { Config transformertypes.Transformer Env *environment.Environment }
RustDockerfileGenerator implements the Transformer interface
func (*RustDockerfileGenerator) DirectoryDetect ¶
func (t *RustDockerfileGenerator) DirectoryDetect(dir string) (map[string][]transformertypes.Artifact, error)
DirectoryDetect runs detect in each sub directory
func (*RustDockerfileGenerator) GetConfig ¶
func (t *RustDockerfileGenerator) GetConfig() (transformertypes.Transformer, *environment.Environment)
GetConfig returns the transformer config
func (*RustDockerfileGenerator) Init ¶
func (t *RustDockerfileGenerator) Init(tc transformertypes.Transformer, env *environment.Environment) (err error)
Init Initializes the transformer
func (*RustDockerfileGenerator) Transform ¶
func (t *RustDockerfileGenerator) Transform(newArtifacts []transformertypes.Artifact, oldArtifacts []transformertypes.Artifact) ([]transformertypes.PathMapping, []transformertypes.Artifact, error)
Transform transforms the artifacts