Skip to content

Commit

Permalink
chore(cloudtrail): clear linter exclusions
Browse files Browse the repository at this point in the history
### Commit Message
chore(cloudtrail): clear linter exclusions

### End Commit Message

----

*By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license*
  • Loading branch information
shivlaks committed May 18, 2020
1 parent 8810bd8 commit 52a6ccc
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 11 deletions.
25 changes: 25 additions & 0 deletions packages/@aws-cdk/aws-cloudtrail/lib/cloudtrail.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ import * as s3 from '@aws-cdk/aws-s3';
import { Construct, Resource, Stack } from '@aws-cdk/core';
import { CfnTrail } from './cloudtrail.generated';

/**
* Properties for an AWS CloudTrail trail
*/
export interface TrailProps {
/**
* For most services, events are recorded in the region where the action occurred.
Expand Down Expand Up @@ -98,9 +101,27 @@ export interface TrailProps {
readonly bucket?: s3.IBucket
}

/**
* Types of events that CloudTrail can log
*/
export enum ReadWriteType {
/**
* Read-only events include API operations that read your resources,
* but don't make changes.
* For example, read-only events include the Amazon EC2 DescribeSecurityGroups
* and DescribeSubnets API operations.
*/
READ_ONLY = 'ReadOnly',
/**
* Write-only events include API operations that modify (or might modify)
* your resources.
* For example, the Amazon EC2 RunInstances and TerminateInstances API
* operations modify your instances.
*/
WRITE_ONLY = 'WriteOnly',
/**
* All events
*/
ALL = 'All'
}

Expand All @@ -120,11 +141,15 @@ export enum ReadWriteType {
export class Trail extends Resource {

/**
* ARN of the CloudTrail trail
* i.e. arn:aws:cloudtrail:us-east-2:123456789012:trail/myCloudTrail
* @attribute
*/
public readonly trailArn: string;

/**
* ARN of the Amazon SNS topic that's associated with the CloudTrail trail,
* i.e. arn:aws:sns:us-east-2:123456789012:mySNSTopic
* @attribute
*/
public readonly trailSnsTopicArn: string;
Expand Down
11 changes: 0 additions & 11 deletions packages/@aws-cdk/aws-cloudtrail/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,6 @@
},
"stability": "experimental",
"maturity": "experimental",
"awslint": {
"exclude": [
"docs-public-apis:@aws-cdk/aws-cloudtrail.Trail.trailArn",
"docs-public-apis:@aws-cdk/aws-cloudtrail.Trail.trailSnsTopicArn",
"docs-public-apis:@aws-cdk/aws-cloudtrail.TrailProps",
"docs-public-apis:@aws-cdk/aws-cloudtrail.ReadWriteType",
"docs-public-apis:@aws-cdk/aws-cloudtrail.ReadWriteType.READ_ONLY",
"docs-public-apis:@aws-cdk/aws-cloudtrail.ReadWriteType.WRITE_ONLY",
"docs-public-apis:@aws-cdk/aws-cloudtrail.ReadWriteType.ALL"
]
},
"awscdkio": {
"announce": false
}
Expand Down

0 comments on commit 52a6ccc

Please sign in to comment.