Function remediateResourceOfType

  • A helper function that returns a strongly-typed resource remediation function, used to check only resources of the specified resource type.

    For example:

    remediateResource: remediateResourceOfType(aws.s3.Bucket, (bucket, args) => {
    bucket.tags = { "foo": "bar" };
    return bucket;
    }),

    Type Parameters

    Parameters

    • resourceClass: (new (name, args, ...rest) => TResource)

      Used to filter this check to only resources of the specified resource class.

    • remediate: TypedResourceRemediation<Unwrap<NonNullable<TArgs>>>

      A callback function that optionally remediates a resource if it violates a policy.

    Returns ResourceRemediation

Generated using TypeDoc