-
Notifications
You must be signed in to change notification settings - Fork 0
/
.projenrc.js
79 lines (65 loc) · 1.85 KB
/
.projenrc.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
const { awscdk, javascript } = require('projen');
const project = new awscdk.AwsCdkConstructLibrary({
cdkVersion: '2.1.0',
defaultReleaseBranch: 'main',
name: '@wheatstalk/oidc-mock',
authorName: 'Josh Kellendonk',
authorEmail: '[email protected]',
repository: 'https://github.com/wheatstalk/oidc-mock.git',
npmAccess: javascript.NpmAccess.PUBLIC,
releaseToNpm: true,
devDeps: [
'uuid@8',
'@types/aws-lambda@^8.10.72',
'@types/aws-serverless-express@^3.3.0',
'nodemon@^2.0.7',
'source-map-support',
'@types/uuid@8',
'oidc-provider@^7.1.1',
'jose@^3.7.1',
'winston',
'ajv',
'ajv-formats',
'aws-sdk',
'got',
'@wheatstalk/aws-cdk-exec',
'expect',
],
depsUpgrade: true,
depsUpgradeOptions: {
ignoreProjen: false,
},
autoApproveUpgrades: true,
autoApproveOptions: {
allowedUsernames: ['misterjoshua'],
},
lambdaAutoDiscover: false,
integrationTestAutoDiscover: false,
});
new awscdk.IntegrationTestAutoDiscover(project, {
cdkDeps: project.cdkDeps,
testdir: project.testdir,
tsconfigPath: project.tsconfigDev.fileName,
integrationTestOptions: {
pathMetadata: true,
},
});
const packageJson = project.tryFindObjectFile('package.json');
packageJson.addOverride('jsii.excludeTypescript', ['src/runtime/**', 'src/jwks/jose.ts']);
project.eslint.allowDevDeps('src/runtime/**');
project.eslint.allowDevDeps('src/jwks/**');
project.bundler.addBundle('src/runtime/api.lambda.ts', {
platform: 'node',
target: 'node14',
sourcemap: true,
externals: ['aws-sdk'],
});
project.addGitIgnore('/.idea');
project.addGitIgnore('/cdk.context.json');
project.addTask('integ:main:test', {
exec: 'cdk-exec --app test/.tmp/main.integ/deploy.cdk.out -at integ',
});
project.upgradeWorkflow.postUpgradeTask.spawn(
project.tasks.tryFind('integ:snapshot-all'),
);
project.synth();