AwsRam

Service-level AWS Resource Access Manager component.

Remarks

Select exactly one capability. resourceShare creates a self-owned, Organisation-scoped resource share and its principal associations. resourceAssociation associates an ARN-bearing resource with an existing share. The association accepts either a name resolved as an active self-owned share or a typed share reference. Changing an associated resource ARN or resolved resource-share ARN replaces the provider association.

Naming:

  • Root type ${namespace}:aws:AwsRam uses either literal capability resource-share or resource-association with logical identity args.identity, yielding ${env}-${projectHash}-<capability>-${sanitised args.identity}.
  • The resource-share capability owns one aws:ram/resourceShare:ResourceShare child with tuple [args.identity], yielding ${env}-${projectHash}-${sanitised args.identity}. Its AWS name uses stackAndPurpose, ${env}-${projectHash}-${args.identity}, and it receives default tags. RAM limits this AWS name to 64 characters, so the 13-character ${env}-${projectHash}- prefix leaves args.identity a maximum of 51 characters.
  • Its aws:ram/principalAssociation:PrincipalAssociation children use tuples [args.identity, args.resourceShare.principals.<key>].
  • The resource-association capability owns one aws:ram/resourceAssociation:ResourceAssociation child with tuple [args.identity], yielding ${env}-${projectHash}-${sanitised args.identity}. It has no component-controlled provider name or tags.

Example

CODE
import { AwsRam } from '@jobcloud/aws-ram';

const sharedParameter = new AwsRam({
  identity: 'sharedDbPassword',
  resourceAssociation: {
    resource: { arn: 'arn:aws:ssm:eu-west-1:000000000000:parameter/sharedDbPassword' },
    resourceShareName: 'sharedParameters',
  },
});

Constructors

new AwsRam( args: AwsRamArgs, options?: ComponentResourceOptions, ): AwsRam

Parameters

  • args (AwsRamArgs)
  • options (ComponentResourceOptions, optional)

Returns

AwsRam

Hierarchy

  • ComponentResource
  • AwsRam

Properties

principalAssociations: Record<string, PrincipalAssociation> | undefined

readonly

Principal associations created for the resource share capability.

resourceArn: Output<string> | undefined

readonly

ARN of the resource associated with the RAM resource share.

resourceAssociation: ResourceAssociation | undefined

readonly

The created RAM resource association.

resourceAssociationId: Output<string> | undefined

readonly

Provider-assigned ID of the RAM resource association.

resourceShare: ResourceShare | undefined

readonly

The created RAM resource share, when the resource-share capability is selected.

resourceShareArn: Output<string> | undefined

readonly

ARN of the created or associated RAM resource share.

resourceShareId: Output<string> | undefined

readonly

Provider-assigned ID of the created RAM resource share.

urn: Output<string>

readonly

Inherited from urn

The stable logical URN used to distinctly address a resource, both before and after deployments.

Methods

getData(): Promise<any>

protectedasync

Inherited from getData

Retrieves the data produces by initialize. The data is immediately available in a derived class's constructor after the super(...) call to ComponentResource.

Returns

  • Promise<any>

getProvider(moduleMember: string): ProviderResource | undefined

Inherited from getProvider

Returns the provider for the given module member, if one exists.

Parameters

  • moduleMember (string)

Returns

  • ProviderResource | undefined

initialize( args: Inputs, opts?: ComponentResourceOptions, name?: string, type?: string, ): Promise<any>

protectedasync

Inherited from initialize

Can be overridden by a subclass to asynchronously initialize data for this component automatically when constructed. The data will be available immediately for subclass constructors to use. To access the data use getData.

Parameters

  • args (Inputs)
  • opts (ComponentResourceOptions, optional)
  • name (string, optional)
  • type (string, optional)

Returns

  • Promise<any>

registerOutputs( outputs?: Inputs | Promise<Inputs> | Output<Inputs>, ): void

protected

Inherited from registerOutputs

Registers synthetic outputs that a component has initialized, usually by allocating other child sub-resources and propagating their resulting property values.

Component resources can call this at the end of their constructor to indicate that they are done creating child resources. This is not strictly necessary as this will automatically be called after the initialize method completes.

Parameters

  • outputs (Inputs | Promise<Inputs> | Output<Inputs>, optional)

Returns

  • void

Static Methods

isInstance(obj: any): obj is ComponentResource<any>

static

Inherited from isInstance

Returns true if the given object is a CustomResource. This is designed to work even when multiple copies of the Pulumi SDK have been loaded into the same process.

Parameters

  • obj (any)

Returns

  • obj is ComponentResource<any>