AwsDeploymentModule
Hierarchy
- AModule<AwsDeploymentModuleSchema, AwsDeployment>
- AwsDeploymentModule
Index
Constructors
Properties
Methods
Constructors
constructor
Parameters
moduleId: string
The ID this module is loaded under.
Returns AwsDeploymentModule
Properties
readonlyinheritedmoduleId
The ID this module was loaded under. It scopes everything the module produces, so the same module class can be loaded more than once.
staticreadonlyinheritedMODULE_PACKAGE
The package the module is registered under, set by Module.
staticreadonlyinheritedMODULE_SCHEMA
The schema of the module's inputs, set by Module.
Methods
onInit
Creates the deployment under its server, anchors what it needs, and links it to the ECR image whose tag it runs.
Parameters
inputs: AwsDeploymentModuleSchema
Returns Promise<(AwsDeployment | AwsDeploymentImageOverlay)[]>
inheritedregisterHooks
To hook custom behavior into Octo's lifecycle for the duration of this module. Override it to return the callbacks you want run.
Returns { postCommitHooks?: PostHookSignature[]; postModelActionHooks?: PostHookSignature[]; postResourceActionHooks?: PostHookSignature[]; preCommitHooks?: PreHookSignature[]; preModelActionHooks?: PreHookSignature[]; preResourceActionHooks?: PreHookSignature[] }
optionalpostCommitHooks?: PostHookSignature[]
optionalpostModelActionHooks?: PostHookSignature[]
optionalpostResourceActionHooks?: PostHookSignature[]
optionalpreCommitHooks?: PreHookSignature[]
optionalpreModelActionHooks?: PreHookSignature[]
optionalpreResourceActionHooks?: PreHookSignature[]
inheritedregisterMetadata
To derive values that both AModule.onInit and this module's actions need - typically facts resolved from another module's anchors, such as an account ID or a region's availability zones. Override it, and the returned object is handed to every action of this module as
actionInputs.metadata.Parameters
inputs: AwsDeploymentModuleSchema
The inputs this module was loaded with.
Returns Promise<Record<string, unknown>>
AwsDeploymentModuledeclares one version of a server's code: its container image (imageandimageTag, orimageUri) and what it needs to run,command,ports,cpu,memoryandtimeoutInSeconds.It creates nothing and knows nothing about where the code runs. The execution that runs it checks the fields its runtime needs, so a field one runtime ignores can still be set.
An image octo publishes is named by its image and tag rather than by its URI, so the image is always pushed before anything runs it. The module publishing the tag,
AwsEcrImageTagModule, must be loaded too; the execution running the deployment fails if the tag is not published where it runs.Nothing: it creates no resources.
None of its own: a new deployment is rolled out by the execution running it, as that execution's
downtimesays.TypeScript
Modules/Deployment/AwsDeployment
An image octo publishes is named by
imageandimageTag, and needs itsAwsEcrImageTagModuleloaded;imageUrinames any other image, which only ECS runs. Lambda needsmemoryof 128 to 10,240 MiB,timeoutInSecondsof 1 to 900, and at most one port.Nothing.
Nothing: it creates no resources. A new
deploymentTagis a new version the execution rolls onto.Deploymentmodel.