package
1.2.6
Repository: https://github.com/redhat-developer/ocdev.git
Documentation: pkg.go.dev

# Functions

CreateConsoleOutputWriterAndChannel is a utility function that returns a pipeWriter and a channel; any strings written to that PipeWriter will be output to the channel (as lines) when the writer closes.
ExecuteCommand executes the given command in the pod's container.
GetBootstrapperImage returns the odo-init bootstrapper image.
GetBuildCommand iterates through the components in the devfile and returns the build command.
GetComponentEnvVar returns true if a list of env vars contains the specified env var If the env exists, it returns the value of it.
GetDebugCommand iterates through the components in the devfile and returns the debug command.
GetDevfileContainerComponents iterates through the components in the devfile and returns a list of devfile container components.
GetDevfileVolumeComponents iterates through the components in the devfile and returns a map of devfile volume components.
GetInitCommand iterates through the components in the devfile and returns the init command.
GetRunCommand iterates through the components in the devfile and returns the run command.
GetTestCommand iterates through the components in the devfile and returns the test command.
GetVolumes iterates through the components in the devfile and returns a map of container name to the devfile volumes.
IsEnvPresent checks if the env variable is present in an array of env variables.
IsPortPresent checks if the port is present in the endpoints array.
IsRestartRequired checks if restart required for run command.
New returns a new command implementation based on the specified devfile command and the known commands.
NewGenericAdapter creates a new GenericAdapter instance based on the provided parameters.
NewPushCommandMap returns the instance of PushCommandsMap.
ValidateAndGetDebugDevfileCommands validates the debug command.
ValidateAndGetPushDevfileCommands validates the build and the run command, if provided through odo push or else checks the devfile for devBuild and devRun.
ValidateAndGetTestDevfileCommands validates the test command.
ValidateCommand validates the given command 1.

# Constants

BinBash The path to sh executable.
DefaultDevfileBuildCommand is a predefined devfile command for build.
DefaultDevfileDebugCommand is a predefined devfile command for debug.
DefaultDevfileInitCommand is a predefined devfile command for init.
DefaultDevfileRunCommand is a predefined devfile command for run.
Default volume size for volumes defined in a devfile.
EnvDebugPort is the env defined in the runtime component container which holds the debug port for remote debugging.
EnvOdoCommandDebug is the env defined in the runtime component container which holds the debug command to be executed.
EnvOdoCommandDebugWorkingDir is the env defined in the runtime component container which holds the work dir for the debug command.
EnvOdoCommandRun is the env defined in the runtime component container which holds the run command to be executed.
EnvOdoCommandRunWorkingDir is the env defined in the runtime component container which holds the work dir for the run command.
EnvProjectsRoot is the env defined for /projects where component mountSources=true.
OdoInitImageContents The path to the odo init image contents.
PostStart is a devfile event.
PostStop is a devfile event.
PreStart is a devfile event.
PreStop is a devfile event.
ShellExecutable is the shell executable.
SupervisordBinaryPath The supervisord binary path inside the container volume mount.
SupervisordConfFile The supervisord configuration file inside the container volume mount.
SupervisordControlCommand sub command which stands for control.
SupervisordCtlSubCommand is the supervisord sub command ctl.
SupervisordInitContainerName The init container name for supervisord.
SupervisordMountPath The supervisord Mount Path for the container mounting the supervisord volume.
SupervisordVolumeName Create a custom name and (hope) that users don't use the *exact* same name in their deployment (occlient.go).

# Structs

AdapterContext is a construct that is common to all adapters.
CommandNames is a struct to store the default and adapter names for devfile commands.
ComponentInfo is a struct that holds information about a component i.e.; pod name, container name, and source mount (if applicable).
DevfileVolume is a struct for Devfile volume that is common to all the adapters.
GenericAdapter provides common code that can be reused by adapters allowing them to focus on more specific behavior.
PushParameters is a struct containing the parameters to be used when pushing to a devfile component.
Storage is a struct that is common to all the adapters.
SyncParameters is a struct containing the parameters to be used when syncing a devfile component.

# Interfaces

ComponentAdapter defines the functions that platform-specific adapters must implement.
ExecClient is a wrapper around ExecCMDInContainer which executes a command in a specific container of a pod.
StorageAdapter defines the storage functions that platform-specific adapters must implement.

# Type aliases

ComponentInfoFactory defines a type for a function which creates a ComponentInfo based on the information provided by the specified DevfileCommand.
DevfileEventType encapsulates constants for devfile events.
PredefinedDevfileCommands encapsulates constants for predefined devfile commands.
PushCommandsMap stores the commands to be executed as per their types.