Skip to content

Latest commit

 

History

History
3485 lines (2142 loc) · 104 KB

API.md

File metadata and controls

3485 lines (2142 loc) · 104 KB

API Reference

Constructs

App

Initializers

import { App } from 'docker-compose-cdk'

new App(props?: AppProps)
Name Type Description
props AppProps No description.

propsOptional

Methods

Name Description
toString Returns a string representation of this construct.
synth No description.
synthToDir No description.

toString
public toString(): string

Returns a string representation of this construct.

synth
public synth(): SynthMetadata
synthToDir
public synthToDir(outdir: string): SynthToDirMetadata
outdirRequired
  • Type: string

Static Functions

Name Description
isConstruct Checks if x is a construct.

isConstruct
import { App } from 'docker-compose-cdk'

App.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


Properties

Name Type Description
node constructs.Node The tree node.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


Config

Initializers

import { Config } from 'docker-compose-cdk'

new Config(scope: Construct, id: string, props: ConfigProps)
Name Type Description
scope constructs.Construct No description.
id string No description.
props ConfigProps No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

propsRequired

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.
fromExternal No description.

isConstruct
import { Config } from 'docker-compose-cdk'

Config.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


fromExternal
import { Config } from 'docker-compose-cdk'

Config.fromExternal(scope: Construct, id: string, fullQualifiedName: string)
scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

fullQualifiedNameRequired
  • Type: string

Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

ConfigBase

Initializers

import { ConfigBase } from 'docker-compose-cdk'

new ConfigBase(scope: Construct, id: string, props?: ResourceOptions)
Name Type Description
scope constructs.Construct No description.
id string No description.
props ResourceOptions No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

propsOptional

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.

isConstruct
import { ConfigBase } from 'docker-compose-cdk'

ConfigBase.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

Network

Initializers

import { Network } from 'docker-compose-cdk'

new Network(scope: Construct, id: string, props?: NetworkProps)
Name Type Description
scope constructs.Construct No description.
id string No description.
props NetworkProps No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

propsOptional

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.
fromExternal No description.

isConstruct
import { Network } from 'docker-compose-cdk'

Network.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


fromExternal
import { Network } from 'docker-compose-cdk'

Network.fromExternal(scope: IConstruct, id: string, fullQualifiedName: string)
scopeRequired
  • Type: constructs.IConstruct

idRequired
  • Type: string

fullQualifiedNameRequired
  • Type: string

Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

NetworkBase

Initializers

import { NetworkBase } from 'docker-compose-cdk'

new NetworkBase(scope: Construct, id: string, props?: ResourceOptions)
Name Type Description
scope constructs.Construct No description.
id string No description.
props ResourceOptions No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

propsOptional

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.

isConstruct
import { NetworkBase } from 'docker-compose-cdk'

NetworkBase.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

Project

Initializers

import { Project } from 'docker-compose-cdk'

new Project(scope: Construct, id: string)
Name Type Description
scope constructs.Construct No description.
id string No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.
of No description.

isConstruct
import { Project } from 'docker-compose-cdk'

Project.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


of
import { Project } from 'docker-compose-cdk'

Project.of(construct: IConstruct)
constructRequired
  • Type: constructs.IConstruct

Properties

Name Type Description
node constructs.Node The tree node.
name string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


nameRequired
public readonly name: string;
  • Type: string

Resource

Initializers

import { Resource } from 'docker-compose-cdk'

new Resource(scope: Construct, id: string, props: ResourceProps)
Name Type Description
scope constructs.Construct No description.
id string No description.
props ResourceProps No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

propsRequired

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.

isConstruct
import { Resource } from 'docker-compose-cdk'

Resource.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

Service

Initializers

import { Service } from 'docker-compose-cdk'

new Service(scope: Construct, id: string, props: ServiceProps)
Name Type Description
scope constructs.Construct No description.
id string No description.
props ServiceProps No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

propsRequired

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.

isConstruct
import { Service } from 'docker-compose-cdk'

Service.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.
dnsNames string[] No description.
disabled boolean No description.
image IDockerImage No description.
replicas number No description.
command string No description.
configs ConfigMapping[] No description.
devices DeviceMapping[] No description.
environment {[ key: string ]: string} No description.
networks NetworkSelection[] No description.
ports IPortMapping[] No description.
privileged boolean No description.
restart RestartPolicy No description.
user string | number No description.
volumes VolumeMapping[] No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

dnsNamesRequired
public readonly dnsNames: string[];
  • Type: string[]

disabledRequired
public readonly disabled: boolean;
  • Type: boolean

imageRequired
public readonly image: IDockerImage;

replicasRequired
public readonly replicas: number;
  • Type: number

commandOptional
public readonly command: string;
  • Type: string

configsOptional
public readonly configs: ConfigMapping[];

devicesOptional
public readonly devices: DeviceMapping[];

environmentOptional
public readonly environment: {[ key: string ]: string};
  • Type: {[ key: string ]: string}

networksOptional
public readonly networks: NetworkSelection[];

portsOptional
public readonly ports: IPortMapping[];

privilegedOptional
public readonly privileged: boolean;
  • Type: boolean

restartOptional
public readonly restart: RestartPolicy;

userOptional
public readonly user: string | number;
  • Type: string | number

volumesOptional
public readonly volumes: VolumeMapping[];

ServiceBase

Initializers

import { ServiceBase } from 'docker-compose-cdk'

new ServiceBase(scope: Construct, id: string, props?: ResourceOptions)
Name Type Description
scope constructs.Construct No description.
id string No description.
props ResourceOptions No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

propsOptional

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.

isConstruct
import { ServiceBase } from 'docker-compose-cdk'

ServiceBase.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.
dnsNames string[] No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

dnsNamesRequired
public readonly dnsNames: string[];
  • Type: string[]

Stage

Initializers

import { Stage } from 'docker-compose-cdk'

new Stage(scope: Construct, id: string)
Name Type Description
scope constructs.Construct No description.
id string No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

Methods

Name Description
toString Returns a string representation of this construct.

toString
public toString(): string

Returns a string representation of this construct.

Static Functions

Name Description
isConstruct Checks if x is a construct.

isConstruct
import { Stage } from 'docker-compose-cdk'

Stage.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


Properties

Name Type Description
node constructs.Node The tree node.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


Volume

Initializers

import { Volume } from 'docker-compose-cdk'

new Volume(scope: Construct, id: string)
Name Type Description
scope constructs.Construct No description.
id string No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.
fromExternal No description.

isConstruct
import { Volume } from 'docker-compose-cdk'

Volume.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


fromExternal
import { Volume } from 'docker-compose-cdk'

Volume.fromExternal(scope: Construct, id: string, fullQualifiedName: string)
scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

fullQualifiedNameRequired
  • Type: string

Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

VolumeBase

Initializers

import { VolumeBase } from 'docker-compose-cdk'

new VolumeBase(scope: Construct, id: string, props?: ResourceOptions)
Name Type Description
scope constructs.Construct No description.
id string No description.
props ResourceOptions No description.

scopeRequired
  • Type: constructs.Construct

idRequired
  • Type: string

propsOptional

Methods

Name Description
toString Returns a string representation of this construct.
render No description.

toString
public toString(): string

Returns a string representation of this construct.

render
public render(): object

Static Functions

Name Description
isConstruct Checks if x is a construct.

isConstruct
import { VolumeBase } from 'docker-compose-cdk'

VolumeBase.isConstruct(x: any)

Checks if x is a construct.

Use this method instead of instanceof to properly detect Construct instances, even when the construct library is symlinked.

Explanation: in JavaScript, multiple copies of the constructs library on disk are seen as independent, completely different libraries. As a consequence, the class Construct in each copy of the constructs library is seen as a different class, and an instance of one class will not test as instanceof the other class. npm install will not create installations like this, but users may manually symlink construct libraries together or use a monorepo tool: in those cases, multiple copies of the constructs library can be accidentally installed, and instanceof will behave unpredictably. It is safest to avoid using instanceof, and using this type-testing method instead.

xRequired
  • Type: any

Any object.


Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

Structs

AppProps

Initializer

import { AppProps } from 'docker-compose-cdk'

const appProps: AppProps = { ... }

Properties

Name Type Description
namingStrategy INamingStrategy No description.

namingStrategyOptional
public readonly namingStrategy: INamingStrategy;

ConfigMapping

Initializer

import { ConfigMapping } from 'docker-compose-cdk'

const configMapping: ConfigMapping = { ... }

Properties

Name Type Description
source IConfig No description.
target string No description.
gid string No description.
mode string No description.
uid string No description.

sourceRequired
public readonly source: IConfig;

targetRequired
public readonly target: string;
  • Type: string

gidOptional
public readonly gid: string;
  • Type: string

modeOptional
public readonly mode: string;
  • Type: string

uidOptional
public readonly uid: string;
  • Type: string

ConfigProps

Initializer

import { ConfigProps } from 'docker-compose-cdk'

const configProps: ConfigProps = { ... }

Properties

Name Type Description
content string No description.

contentRequired
public readonly content: string;
  • Type: string

DeviceMapping

Initializer

import { DeviceMapping } from 'docker-compose-cdk'

const deviceMapping: DeviceMapping = { ... }

Properties

Name Type Description
source string No description.
target string No description.

sourceRequired
public readonly source: string;
  • Type: string

targetRequired
public readonly target: string;
  • Type: string

Names

Initializer

import { Names } from 'docker-compose-cdk'

const names: Names = { ... }

Properties

Name Type Description
fullQualified string No description.
local string No description.

fullQualifiedRequired
public readonly fullQualified: string;
  • Type: string

localRequired
public readonly local: string;
  • Type: string

NetworkDriverOptions

Initializer

import { NetworkDriverOptions } from 'docker-compose-cdk'

const networkDriverOptions: NetworkDriverOptions = { ... }

Properties

Name Type Description
parent string No description.

parentOptional
public readonly parent: string;
  • Type: string

NetworkIpam

Initializer

import { NetworkIpam } from 'docker-compose-cdk'

const networkIpam: NetworkIpam = { ... }

Properties

Name Type Description
config NetworkIpamConfig[] No description.

configOptional
public readonly config: NetworkIpamConfig[];

NetworkIpamConfig

Initializer

import { NetworkIpamConfig } from 'docker-compose-cdk'

const networkIpamConfig: NetworkIpamConfig = { ... }

Properties

Name Type Description
gateway string No description.
ipRange string No description.
subnet string No description.

gatewayOptional
public readonly gateway: string;
  • Type: string

ipRangeOptional
public readonly ipRange: string;
  • Type: string

subnetOptional
public readonly subnet: string;
  • Type: string

NetworkProps

Initializer

import { NetworkProps } from 'docker-compose-cdk'

const networkProps: NetworkProps = { ... }

Properties

Name Type Description
driver NetworkDriver No description.
driverOptions NetworkDriverOptions No description.
ipam NetworkIpam No description.

driverOptional
public readonly driver: NetworkDriver;

driverOptionsOptional
public readonly driverOptions: NetworkDriverOptions;

ipamOptional
public readonly ipam: NetworkIpam;

NetworkSelection

Initializer

import { NetworkSelection } from 'docker-compose-cdk'

const networkSelection: NetworkSelection = { ... }

Properties

Name Type Description
network INetwork No description.
ipV4Address string No description.

networkRequired
public readonly network: INetwork;

ipV4AddressOptional
public readonly ipV4Address: string;
  • Type: string

ResourceOptions

Initializer

import { ResourceOptions } from 'docker-compose-cdk'

const resourceOptions: ResourceOptions = { ... }

Properties

Name Type Description
fullQualifiedName string No description.
name string No description.

fullQualifiedNameOptional
public readonly fullQualifiedName: string;
  • Type: string

nameOptional
public readonly name: string;
  • Type: string

ResourceProps

Initializer

import { ResourceProps } from 'docker-compose-cdk'

const resourceProps: ResourceProps = { ... }

Properties

Name Type Description
fullQualifiedName string No description.
name string No description.
resourceType string No description.

fullQualifiedNameOptional
public readonly fullQualifiedName: string;
  • Type: string

nameOptional
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

ServiceProps

Initializer

import { ServiceProps } from 'docker-compose-cdk'

const serviceProps: ServiceProps = { ... }

Properties

Name Type Description
image IDockerImage No description.
command string No description.
configs ConfigMapping[] No description.
devices DeviceMapping[] No description.
disabled boolean No description.
environment {[ key: string ]: string} No description.
networks NetworkSelection[] No description.
ports IPortMapping[] No description.
privileged boolean No description.
replicas number No description.
restart RestartPolicy No description.
user string | number No description.
volumes VolumeMapping[] No description.

imageRequired
public readonly image: IDockerImage;

commandOptional
public readonly command: string;
  • Type: string

configsOptional
public readonly configs: ConfigMapping[];

devicesOptional
public readonly devices: DeviceMapping[];

disabledOptional
public readonly disabled: boolean;
  • Type: boolean

environmentOptional
public readonly environment: {[ key: string ]: string};
  • Type: {[ key: string ]: string}

networksOptional
public readonly networks: NetworkSelection[];

portsOptional
public readonly ports: IPortMapping[];

privilegedOptional
public readonly privileged: boolean;
  • Type: boolean

replicasOptional
public readonly replicas: number;
  • Type: number

restartOptional
public readonly restart: RestartPolicy;

userOptional
public readonly user: string | number;
  • Type: string | number

volumesOptional
public readonly volumes: VolumeMapping[];

SynthMetadata

Initializer

import { SynthMetadata } from 'docker-compose-cdk'

const synthMetadata: SynthMetadata = { ... }

Properties

Name Type Description
projects SynthProjectResult[] No description.

projectsRequired
public readonly projects: SynthProjectResult[];

SynthProjectReference

Initializer

import { SynthProjectReference } from 'docker-compose-cdk'

const synthProjectReference: SynthProjectReference = { ... }

Properties

Name Type Description
composeHash string No description.
name string No description.

composeHashRequired
public readonly composeHash: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

SynthProjectResult

Initializer

import { SynthProjectResult } from 'docker-compose-cdk'

const synthProjectResult: SynthProjectResult = { ... }

Properties

Name Type Description
composeHash string No description.
name string No description.
compose object No description.

composeHashRequired
public readonly composeHash: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

composeRequired
public readonly compose: object;
  • Type: object

SynthToDirMetadata

Initializer

import { SynthToDirMetadata } from 'docker-compose-cdk'

const synthToDirMetadata: SynthToDirMetadata = { ... }

Properties

Name Type Description
projects SynthProjectReference[] No description.

projectsRequired
public readonly projects: SynthProjectReference[];

VolumeMapping

Initializer

import { VolumeMapping } from 'docker-compose-cdk'

const volumeMapping: VolumeMapping = { ... }

Properties

Name Type Description
source string | IVolume No description.
target string No description.
readonly boolean No description.

sourceRequired
public readonly source: string | IVolume;

targetRequired
public readonly target: string;
  • Type: string

readonlyOptional
public readonly readonly: boolean;
  • Type: boolean

Classes

DefaultNamingStrategy

Initializers

import { DefaultNamingStrategy } from 'docker-compose-cdk'

new DefaultNamingStrategy()
Name Type Description

Methods

Name Description
generateNames No description.

generateNames
public generateNames(construct: IConstruct): Names
constructRequired
  • Type: constructs.IConstruct

DockerImage

Initializers

import { DockerImage } from 'docker-compose-cdk'

new DockerImage()
Name Type Description

Static Functions

Name Description
ghcr No description.
hub No description.

ghcr
import { DockerImage } from 'docker-compose-cdk'

DockerImage.ghcr(userOrOrg: string, image: string, tag?: string)
userOrOrgRequired
  • Type: string

imageRequired
  • Type: string

tagOptional
  • Type: string

hub
import { DockerImage } from 'docker-compose-cdk'

DockerImage.hub(image: string, tag?: string)
imageRequired
  • Type: string

tagOptional
  • Type: string

PortMapping

Initializers

import { PortMapping } from 'docker-compose-cdk'

new PortMapping()
Name Type Description

Static Functions

Name Description
http No description.
https No description.
port No description.

http
import { PortMapping } from 'docker-compose-cdk'

PortMapping.http()
https
import { PortMapping } from 'docker-compose-cdk'

PortMapping.https()
port
import { PortMapping } from 'docker-compose-cdk'

PortMapping.port(port: number)
portRequired
  • Type: number

Protocols

IConfig

Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

IDockerImage

Properties

Name Type Description
image string No description.
tag string No description.

imageRequired
public readonly image: string;
  • Type: string

tagOptional
public readonly tag: string;
  • Type: string

INamingStrategy

Methods

Name Description
generateNames No description.

generateNames
public generateNames(construct: IConstruct): Names
constructRequired
  • Type: constructs.IConstruct

INetwork

Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

IPortMapping

Properties

Name Type Description
container number No description.
host number No description.

containerRequired
public readonly container: number;
  • Type: number

hostRequired
public readonly host: number;
  • Type: number

IProject

IResource

Methods

Name Description
render No description.

render
public render(): object

Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

IService

Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

IVolume

Properties

Name Type Description
node constructs.Node The tree node.
fullQualifiedName string No description.
name string No description.
resourceType string No description.

nodeRequired
public readonly node: Node;
  • Type: constructs.Node

The tree node.


fullQualifiedNameRequired
public readonly fullQualifiedName: string;
  • Type: string

nameRequired
public readonly name: string;
  • Type: string

resourceTypeRequired
public readonly resourceType: string;
  • Type: string

Enums

NetworkDriver

Members

Name Description
BRIDGE No description.
MACVLAN No description.

BRIDGE

MACVLAN

RestartPolicy

Members

Name Description
NO No description.
UNLESS_STOPPED No description.
ALWAYS No description.
ON_FAILURE No description.

NO

UNLESS_STOPPED

ALWAYS

ON_FAILURE