UNPKG

1.76 kBTypeScriptView Raw
1import * as logs from '@aws-cdk/aws-logs';
2import * as s3 from '@aws-cdk/aws-s3';
3/**
4 * Information about logs built to an S3 bucket for a build project.
5 */
6export interface S3LoggingOptions {
7 /**
8 * Encrypt the S3 build log output
9 *
10 * @default true
11 */
12 readonly encrypted?: boolean;
13 /**
14 * The S3 Bucket to send logs to
15 */
16 readonly bucket: s3.IBucket;
17 /**
18 * The path prefix for S3 logs
19 *
20 * @default - no prefix
21 */
22 readonly prefix?: string;
23 /**
24 * The current status of the logs in Amazon CloudWatch Logs for a build project
25 *
26 * @default true
27 */
28 readonly enabled?: boolean;
29}
30/**
31 * Information about logs built to a CloudWatch Log Group for a build project.
32 */
33export interface CloudWatchLoggingOptions {
34 /**
35 * The Log Group to send logs to
36 *
37 * @default - no log group specified
38 */
39 readonly logGroup?: logs.ILogGroup;
40 /**
41 * The prefix of the stream name of the Amazon CloudWatch Logs
42 *
43 * @default - no prefix
44 */
45 readonly prefix?: string;
46 /**
47 * The current status of the logs in Amazon CloudWatch Logs for a build project
48 *
49 * @default true
50 */
51 readonly enabled?: boolean;
52}
53/**
54 * Information about logs for the build project. A project can create logs in Amazon CloudWatch Logs, an S3 bucket, or both.
55 */
56export interface LoggingOptions {
57 /**
58 * Information about logs built to an S3 bucket for a build project.
59 *
60 * @default - disabled
61 */
62 readonly s3?: S3LoggingOptions;
63 /**
64 * Information about Amazon CloudWatch Logs for a build project.
65 *
66 * @default - enabled
67 */
68 readonly cloudWatch?: CloudWatchLoggingOptions;
69}