@taimos/projen 0.1.84 → 0.1.86

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/API.md CHANGED
@@ -567,6 +567,265 @@ The generated production release workflow.
567
567
  ---
568
568
 
569
569
 
570
+ ### Gitleaks <a name="Gitleaks" id="@taimos/projen.Gitleaks"></a>
571
+
572
+ gitleaks secret-scanning for a project: a `.gitleaks.toml` config that extends the bundled default ruleset plus tightly path-scoped allowlists, and a pull-request workflow that scans the full git history against it.
573
+
574
+ projen has no native gitleaks component, so both artifacts are generated here
575
+ to stay in the "never hand-edit generated files" model. Requires GitHub to be
576
+ enabled on the project.
577
+
578
+ #### Initializers <a name="Initializers" id="@taimos/projen.Gitleaks.Initializer"></a>
579
+
580
+ ```typescript
581
+ import { Gitleaks } from '@taimos/projen'
582
+
583
+ new Gitleaks(scope: TypeScriptProject, options?: GitleaksOptions)
584
+ ```
585
+
586
+ | **Name** | **Type** | **Description** |
587
+ | --- | --- | --- |
588
+ | <code><a href="#@taimos/projen.Gitleaks.Initializer.parameter.scope">scope</a></code> | <code>projen.typescript.TypeScriptProject</code> | *No description.* |
589
+ | <code><a href="#@taimos/projen.Gitleaks.Initializer.parameter.options">options</a></code> | <code><a href="#@taimos/projen.GitleaksOptions">GitleaksOptions</a></code> | *No description.* |
590
+
591
+ ---
592
+
593
+ ##### `scope`<sup>Required</sup> <a name="scope" id="@taimos/projen.Gitleaks.Initializer.parameter.scope"></a>
594
+
595
+ - *Type:* projen.typescript.TypeScriptProject
596
+
597
+ ---
598
+
599
+ ##### `options`<sup>Optional</sup> <a name="options" id="@taimos/projen.Gitleaks.Initializer.parameter.options"></a>
600
+
601
+ - *Type:* <a href="#@taimos/projen.GitleaksOptions">GitleaksOptions</a>
602
+
603
+ ---
604
+
605
+ #### Methods <a name="Methods" id="Methods"></a>
606
+
607
+ | **Name** | **Description** |
608
+ | --- | --- |
609
+ | <code><a href="#@taimos/projen.Gitleaks.toString">toString</a></code> | Returns a string representation of this construct. |
610
+ | <code><a href="#@taimos/projen.Gitleaks.with">with</a></code> | Applies one or more mixins to this construct. |
611
+ | <code><a href="#@taimos/projen.Gitleaks.postProjectCreation">postProjectCreation</a></code> | Called once, right after `postSynthesize()`, only when the project is created for the first time. |
612
+ | <code><a href="#@taimos/projen.Gitleaks.postSynthesize">postSynthesize</a></code> | Called after synthesis. |
613
+ | <code><a href="#@taimos/projen.Gitleaks.preSynthesize">preSynthesize</a></code> | Called before synthesis. |
614
+ | <code><a href="#@taimos/projen.Gitleaks.projectCreation">projectCreation</a></code> | Called once, right after `synthesize()`, only when the project is created for the first time. |
615
+ | <code><a href="#@taimos/projen.Gitleaks.synthesize">synthesize</a></code> | Synthesizes files to the project output directory. |
616
+
617
+ ---
618
+
619
+ ##### `toString` <a name="toString" id="@taimos/projen.Gitleaks.toString"></a>
620
+
621
+ ```typescript
622
+ public toString(): string
623
+ ```
624
+
625
+ Returns a string representation of this construct.
626
+
627
+ ##### `with` <a name="with" id="@taimos/projen.Gitleaks.with"></a>
628
+
629
+ ```typescript
630
+ public with(mixins: ...IMixin[]): IConstruct
631
+ ```
632
+
633
+ Applies one or more mixins to this construct.
634
+
635
+ Mixins are applied in order. The list of constructs is captured at the
636
+ start of the call, so constructs added by a mixin will not be visited.
637
+ Use multiple `with()` calls if subsequent mixins should apply to added
638
+ constructs.
639
+
640
+ ###### `mixins`<sup>Required</sup> <a name="mixins" id="@taimos/projen.Gitleaks.with.parameter.mixins"></a>
641
+
642
+ - *Type:* ...constructs.IMixin[]
643
+
644
+ The mixins to apply.
645
+
646
+ ---
647
+
648
+ ##### `postProjectCreation` <a name="postProjectCreation" id="@taimos/projen.Gitleaks.postProjectCreation"></a>
649
+
650
+ ```typescript
651
+ public postProjectCreation(initProject: InitProject): void
652
+ ```
653
+
654
+ Called once, right after `postSynthesize()`, only when the project is created for the first time.
655
+
656
+ It does not run on later `projen` invocations. It only fires for `projen new` (or `Projects.createProject`).
657
+ It is also skipped when post-synthesis steps are disabled, e.g. `--no-post` or `PROJEN_DISABLE_POST`.
658
+ Use it for one-off setup that can be turned off by the user, like running a task to give the user immediate
659
+ feedback on their new project. Order across components is not guaranteed.
660
+
661
+ ###### `initProject`<sup>Required</sup> <a name="initProject" id="@taimos/projen.Gitleaks.postProjectCreation.parameter.initProject"></a>
662
+
663
+ - *Type:* projen.InitProject
664
+
665
+ Details about how the project was created, e.g. its type and the original CLI args.
666
+
667
+ ---
668
+
669
+ ##### `postSynthesize` <a name="postSynthesize" id="@taimos/projen.Gitleaks.postSynthesize"></a>
670
+
671
+ ```typescript
672
+ public postSynthesize(): void
673
+ ```
674
+
675
+ Called after synthesis.
676
+
677
+ Order is *not* guaranteed.
678
+
679
+ ##### `preSynthesize` <a name="preSynthesize" id="@taimos/projen.Gitleaks.preSynthesize"></a>
680
+
681
+ ```typescript
682
+ public preSynthesize(): void
683
+ ```
684
+
685
+ Called before synthesis.
686
+
687
+ ##### `projectCreation` <a name="projectCreation" id="@taimos/projen.Gitleaks.projectCreation"></a>
688
+
689
+ ```typescript
690
+ public projectCreation(initProject: InitProject): void
691
+ ```
692
+
693
+ Called once, right after `synthesize()`, only when the project is created for the first time.
694
+
695
+ It does not run on later `projen` invocations. It only fires for `projen new` (or `Projects.createProject`).
696
+ Use it for deterministic, one-off file generation. Order across components is not guaranteed.
697
+
698
+ ###### `initProject`<sup>Required</sup> <a name="initProject" id="@taimos/projen.Gitleaks.projectCreation.parameter.initProject"></a>
699
+
700
+ - *Type:* projen.InitProject
701
+
702
+ Details about how the project was created, e.g. its type and the original CLI args.
703
+
704
+ ---
705
+
706
+ ##### `synthesize` <a name="synthesize" id="@taimos/projen.Gitleaks.synthesize"></a>
707
+
708
+ ```typescript
709
+ public synthesize(): void
710
+ ```
711
+
712
+ Synthesizes files to the project output directory.
713
+
714
+ #### Static Functions <a name="Static Functions" id="Static Functions"></a>
715
+
716
+ | **Name** | **Description** |
717
+ | --- | --- |
718
+ | <code><a href="#@taimos/projen.Gitleaks.isConstruct">isConstruct</a></code> | Checks if `x` is a construct. |
719
+ | <code><a href="#@taimos/projen.Gitleaks.isComponent">isComponent</a></code> | Test whether the given construct is a component. |
720
+
721
+ ---
722
+
723
+ ##### `isConstruct` <a name="isConstruct" id="@taimos/projen.Gitleaks.isConstruct"></a>
724
+
725
+ ```typescript
726
+ import { Gitleaks } from '@taimos/projen'
727
+
728
+ Gitleaks.isConstruct(x: any)
729
+ ```
730
+
731
+ Checks if `x` is a construct.
732
+
733
+ Use this method instead of `instanceof` to properly detect `Construct`
734
+ instances, even when the construct library is symlinked.
735
+
736
+ Explanation: in JavaScript, multiple copies of the `constructs` library on
737
+ disk are seen as independent, completely different libraries. As a
738
+ consequence, the class `Construct` in each copy of the `constructs` library
739
+ is seen as a different class, and an instance of one class will not test as
740
+ `instanceof` the other class. `npm install` will not create installations
741
+ like this, but users may manually symlink construct libraries together or
742
+ use a monorepo tool: in those cases, multiple copies of the `constructs`
743
+ library can be accidentally installed, and `instanceof` will behave
744
+ unpredictably. It is safest to avoid using `instanceof`, and using
745
+ this type-testing method instead.
746
+
747
+ ###### `x`<sup>Required</sup> <a name="x" id="@taimos/projen.Gitleaks.isConstruct.parameter.x"></a>
748
+
749
+ - *Type:* any
750
+
751
+ Any object.
752
+
753
+ ---
754
+
755
+ ##### `isComponent` <a name="isComponent" id="@taimos/projen.Gitleaks.isComponent"></a>
756
+
757
+ ```typescript
758
+ import { Gitleaks } from '@taimos/projen'
759
+
760
+ Gitleaks.isComponent(x: any)
761
+ ```
762
+
763
+ Test whether the given construct is a component.
764
+
765
+ ###### `x`<sup>Required</sup> <a name="x" id="@taimos/projen.Gitleaks.isComponent.parameter.x"></a>
766
+
767
+ - *Type:* any
768
+
769
+ ---
770
+
771
+ #### Properties <a name="Properties" id="Properties"></a>
772
+
773
+ | **Name** | **Type** | **Description** |
774
+ | --- | --- | --- |
775
+ | <code><a href="#@taimos/projen.Gitleaks.property.node">node</a></code> | <code>constructs.Node</code> | The tree node. |
776
+ | <code><a href="#@taimos/projen.Gitleaks.property.project">project</a></code> | <code>projen.Project</code> | *No description.* |
777
+ | <code><a href="#@taimos/projen.Gitleaks.property.configFile">configFile</a></code> | <code>projen.TextFile</code> | The generated `.gitleaks.toml`. |
778
+ | <code><a href="#@taimos/projen.Gitleaks.property.workflow">workflow</a></code> | <code>projen.github.GithubWorkflow</code> | The generated pull-request scanning workflow. |
779
+
780
+ ---
781
+
782
+ ##### `node`<sup>Required</sup> <a name="node" id="@taimos/projen.Gitleaks.property.node"></a>
783
+
784
+ ```typescript
785
+ public readonly node: Node;
786
+ ```
787
+
788
+ - *Type:* constructs.Node
789
+
790
+ The tree node.
791
+
792
+ ---
793
+
794
+ ##### `project`<sup>Required</sup> <a name="project" id="@taimos/projen.Gitleaks.property.project"></a>
795
+
796
+ ```typescript
797
+ public readonly project: Project;
798
+ ```
799
+
800
+ - *Type:* projen.Project
801
+
802
+ ---
803
+
804
+ ##### `configFile`<sup>Required</sup> <a name="configFile" id="@taimos/projen.Gitleaks.property.configFile"></a>
805
+
806
+ ```typescript
807
+ public readonly configFile: TextFile;
808
+ ```
809
+
810
+ - *Type:* projen.TextFile
811
+
812
+ The generated `.gitleaks.toml`.
813
+
814
+ ---
815
+
816
+ ##### `workflow`<sup>Required</sup> <a name="workflow" id="@taimos/projen.Gitleaks.property.workflow"></a>
817
+
818
+ ```typescript
819
+ public readonly workflow: GithubWorkflow;
820
+ ```
821
+
822
+ - *Type:* projen.github.GithubWorkflow
823
+
824
+ The generated pull-request scanning workflow.
825
+
826
+ ---
827
+
828
+
570
829
  ### MonorepoProject <a name="MonorepoProject" id="@taimos/projen.MonorepoProject"></a>
571
830
 
572
831
  Private PNPM-workspace monorepo root, following Taimos ADR-0002.
@@ -1240,6 +1499,7 @@ When given a project, this it the project itself.
1240
1499
  | <code><a href="#@taimos/projen.MonorepoProject.property.amplifyDeploy">amplifyDeploy</a></code> | <code><a href="#@taimos/projen.GitHubAmplifyDeploy">GitHubAmplifyDeploy</a></code> | The Amplify deploy workflows, when `amplifyDeployOptions` is set. |
1241
1500
  | <code><a href="#@taimos/projen.MonorepoProject.property.amplifyFile">amplifyFile</a></code> | <code>projen.YamlFile</code> | The generated `amplify.yml`, if any Amplify apps were configured. |
1242
1501
  | <code><a href="#@taimos/projen.MonorepoProject.property.assignApprover">assignApprover</a></code> | <code>projen-pipelines.GitHubAssignApprover</code> | The PR approver assignment, if enabled. |
1502
+ | <code><a href="#@taimos/projen.MonorepoProject.property.gitleaks">gitleaks</a></code> | <code><a href="#@taimos/projen.Gitleaks">Gitleaks</a></code> | The gitleaks secret-scanning component, if enabled. |
1243
1503
  | <code><a href="#@taimos/projen.MonorepoProject.property.productionRelease">productionRelease</a></code> | <code><a href="#@taimos/projen.GitHubProductionRelease">GitHubProductionRelease</a></code> | The production release workflow, if enabled. |
1244
1504
 
1245
1505
  ---
@@ -2013,6 +2273,18 @@ The PR approver assignment, if enabled.
2013
2273
 
2014
2274
  ---
2015
2275
 
2276
+ ##### `gitleaks`<sup>Optional</sup> <a name="gitleaks" id="@taimos/projen.MonorepoProject.property.gitleaks"></a>
2277
+
2278
+ ```typescript
2279
+ public readonly gitleaks: Gitleaks;
2280
+ ```
2281
+
2282
+ - *Type:* <a href="#@taimos/projen.Gitleaks">Gitleaks</a>
2283
+
2284
+ The gitleaks secret-scanning component, if enabled.
2285
+
2286
+ ---
2287
+
2016
2288
  ##### `productionRelease`<sup>Optional</sup> <a name="productionRelease" id="@taimos/projen.MonorepoProject.property.productionRelease"></a>
2017
2289
 
2018
2290
  ```typescript
@@ -11042,6 +11314,145 @@ The name of the generated workflow (and its `.yml` file).
11042
11314
 
11043
11315
  ---
11044
11316
 
11317
+ ### GitleaksAllowlist <a name="GitleaksAllowlist" id="@taimos/projen.GitleaksAllowlist"></a>
11318
+
11319
+ One path-scoped allowlist entry for the generated `.gitleaks.toml`.
11320
+
11321
+ Each entry is rendered as a `[[allowlists]]` block. Keep every allowlist as
11322
+ tightly path-scoped as possible so it cannot mask a real secret elsewhere in
11323
+ the repo.
11324
+
11325
+ #### Initializer <a name="Initializer" id="@taimos/projen.GitleaksAllowlist.Initializer"></a>
11326
+
11327
+ ```typescript
11328
+ import { GitleaksAllowlist } from '@taimos/projen'
11329
+
11330
+ const gitleaksAllowlist: GitleaksAllowlist = { ... }
11331
+ ```
11332
+
11333
+ #### Properties <a name="Properties" id="Properties"></a>
11334
+
11335
+ | **Name** | **Type** | **Description** |
11336
+ | --- | --- | --- |
11337
+ | <code><a href="#@taimos/projen.GitleaksAllowlist.property.description">description</a></code> | <code>string</code> | Human-readable description of what this allowlist exempts and why. |
11338
+ | <code><a href="#@taimos/projen.GitleaksAllowlist.property.condition">condition</a></code> | <code>string</code> | gitleaks `condition` combining `paths` and `regexes` (`AND` requires both). |
11339
+ | <code><a href="#@taimos/projen.GitleaksAllowlist.property.paths">paths</a></code> | <code>string[]</code> | Regex paths the allowlist applies to (rendered as gitleaks `paths`), e.g. `['^\\.npmrc$']`. Omit to apply the regexes repo-wide (discouraged). |
11340
+ | <code><a href="#@taimos/projen.GitleaksAllowlist.property.regexes">regexes</a></code> | <code>string[]</code> | Regexes matching the allowed secret values (rendered as gitleaks `regexes`). |
11341
+ | <code><a href="#@taimos/projen.GitleaksAllowlist.property.regexTarget">regexTarget</a></code> | <code>string</code> | gitleaks `regexTarget` (`secret` \| `match` \| `line`). |
11342
+
11343
+ ---
11344
+
11345
+ ##### `description`<sup>Required</sup> <a name="description" id="@taimos/projen.GitleaksAllowlist.property.description"></a>
11346
+
11347
+ ```typescript
11348
+ public readonly description: string;
11349
+ ```
11350
+
11351
+ - *Type:* string
11352
+
11353
+ Human-readable description of what this allowlist exempts and why.
11354
+
11355
+ ---
11356
+
11357
+ ##### `condition`<sup>Optional</sup> <a name="condition" id="@taimos/projen.GitleaksAllowlist.property.condition"></a>
11358
+
11359
+ ```typescript
11360
+ public readonly condition: string;
11361
+ ```
11362
+
11363
+ - *Type:* string
11364
+ - *Default:* gitleaks default (OR)
11365
+
11366
+ gitleaks `condition` combining `paths` and `regexes` (`AND` requires both).
11367
+
11368
+ ---
11369
+
11370
+ ##### `paths`<sup>Optional</sup> <a name="paths" id="@taimos/projen.GitleaksAllowlist.property.paths"></a>
11371
+
11372
+ ```typescript
11373
+ public readonly paths: string[];
11374
+ ```
11375
+
11376
+ - *Type:* string[]
11377
+ - *Default:* no path scope
11378
+
11379
+ Regex paths the allowlist applies to (rendered as gitleaks `paths`), e.g. `['^\\.npmrc$']`. Omit to apply the regexes repo-wide (discouraged).
11380
+
11381
+ ---
11382
+
11383
+ ##### `regexes`<sup>Optional</sup> <a name="regexes" id="@taimos/projen.GitleaksAllowlist.property.regexes"></a>
11384
+
11385
+ ```typescript
11386
+ public readonly regexes: string[];
11387
+ ```
11388
+
11389
+ - *Type:* string[]
11390
+ - *Default:* no value regexes
11391
+
11392
+ Regexes matching the allowed secret values (rendered as gitleaks `regexes`).
11393
+
11394
+ Omit to allow anything on the scoped paths.
11395
+
11396
+ ---
11397
+
11398
+ ##### `regexTarget`<sup>Optional</sup> <a name="regexTarget" id="@taimos/projen.GitleaksAllowlist.property.regexTarget"></a>
11399
+
11400
+ ```typescript
11401
+ public readonly regexTarget: string;
11402
+ ```
11403
+
11404
+ - *Type:* string
11405
+ - *Default:* gitleaks default
11406
+
11407
+ gitleaks `regexTarget` (`secret` | `match` | `line`).
11408
+
11409
+ ---
11410
+
11411
+ ### GitleaksOptions <a name="GitleaksOptions" id="@taimos/projen.GitleaksOptions"></a>
11412
+
11413
+ #### Initializer <a name="Initializer" id="@taimos/projen.GitleaksOptions.Initializer"></a>
11414
+
11415
+ ```typescript
11416
+ import { GitleaksOptions } from '@taimos/projen'
11417
+
11418
+ const gitleaksOptions: GitleaksOptions = { ... }
11419
+ ```
11420
+
11421
+ #### Properties <a name="Properties" id="Properties"></a>
11422
+
11423
+ | **Name** | **Type** | **Description** |
11424
+ | --- | --- | --- |
11425
+ | <code><a href="#@taimos/projen.GitleaksOptions.property.allowlists">allowlists</a></code> | <code><a href="#@taimos/projen.GitleaksAllowlist">GitleaksAllowlist</a>[]</code> | Path-scoped allowlists for known false positives, appended after `[extend] useDefault = true`. |
11426
+ | <code><a href="#@taimos/projen.GitleaksOptions.property.version">version</a></code> | <code>string</code> | The gitleaks version downloaded in CI. |
11427
+
11428
+ ---
11429
+
11430
+ ##### `allowlists`<sup>Optional</sup> <a name="allowlists" id="@taimos/projen.GitleaksOptions.property.allowlists"></a>
11431
+
11432
+ ```typescript
11433
+ public readonly allowlists: GitleaksAllowlist[];
11434
+ ```
11435
+
11436
+ - *Type:* <a href="#@taimos/projen.GitleaksAllowlist">GitleaksAllowlist</a>[]
11437
+ - *Default:* []
11438
+
11439
+ Path-scoped allowlists for known false positives, appended after `[extend] useDefault = true`.
11440
+
11441
+ ---
11442
+
11443
+ ##### `version`<sup>Optional</sup> <a name="version" id="@taimos/projen.GitleaksOptions.property.version"></a>
11444
+
11445
+ ```typescript
11446
+ public readonly version: string;
11447
+ ```
11448
+
11449
+ - *Type:* string
11450
+ - *Default:* '8.30.1'
11451
+
11452
+ The gitleaks version downloaded in CI.
11453
+
11454
+ ---
11455
+
11045
11456
  ### MonorepoAmplifyApp <a name="MonorepoAmplifyApp" id="@taimos/projen.MonorepoAmplifyApp"></a>
11046
11457
 
11047
11458
  One AWS Amplify Hosting application served from a workspace package.
@@ -11415,6 +11826,8 @@ const monorepoProjectOptions: MonorepoProjectOptions = { ... }
11415
11826
  | <code><a href="#@taimos/projen.MonorepoProjectOptions.property.assignApprover">assignApprover</a></code> | <code>boolean</code> | Whether to assign PR approvers via `GitHubAssignApprover`. |
11416
11827
  | <code><a href="#@taimos/projen.MonorepoProjectOptions.property.cdkServerless">cdkServerless</a></code> | <code>boolean</code> | Whether to add `cdk-serverless` as a workspace dev dependency. |
11417
11828
  | <code><a href="#@taimos/projen.MonorepoProjectOptions.property.defaultApprovers">defaultApprovers</a></code> | <code>string[]</code> | Approvers assigned when no author-specific mapping matches. |
11829
+ | <code><a href="#@taimos/projen.MonorepoProjectOptions.property.gitleaks">gitleaks</a></code> | <code>boolean</code> | Whether to add gitleaks secret-scanning: a `.gitleaks.toml` config plus a pull-request workflow that scans the full git history (see `Gitleaks`). |
11830
+ | <code><a href="#@taimos/projen.MonorepoProjectOptions.property.gitleaksOptions">gitleaksOptions</a></code> | <code><a href="#@taimos/projen.GitleaksOptions">GitleaksOptions</a></code> | Options for the gitleaks component. |
11418
11831
  | <code><a href="#@taimos/projen.MonorepoProjectOptions.property.nodeVersion">nodeVersion</a></code> | <code>string</code> | The Node.js version used in the generated build workflow. |
11419
11832
  | <code><a href="#@taimos/projen.MonorepoProjectOptions.property.pnpmWorkspaceVersion">pnpmWorkspaceVersion</a></code> | <code>string</code> | The pnpm version pinned for the workspace and CI. |
11420
11833
  | <code><a href="#@taimos/projen.MonorepoProjectOptions.property.productionRelease">productionRelease</a></code> | <code>boolean</code> | Whether to add a manual "Production Release" workflow that promotes a branch to the production branch (see `GitHubProductionRelease`). |
@@ -13697,6 +14110,34 @@ Only used when `assignApprover` is enabled.
13697
14110
 
13698
14111
  ---
13699
14112
 
14113
+ ##### `gitleaks`<sup>Optional</sup> <a name="gitleaks" id="@taimos/projen.MonorepoProjectOptions.property.gitleaks"></a>
14114
+
14115
+ ```typescript
14116
+ public readonly gitleaks: boolean;
14117
+ ```
14118
+
14119
+ - *Type:* boolean
14120
+ - *Default:* false
14121
+
14122
+ Whether to add gitleaks secret-scanning: a `.gitleaks.toml` config plus a pull-request workflow that scans the full git history (see `Gitleaks`).
14123
+
14124
+ ---
14125
+
14126
+ ##### `gitleaksOptions`<sup>Optional</sup> <a name="gitleaksOptions" id="@taimos/projen.MonorepoProjectOptions.property.gitleaksOptions"></a>
14127
+
14128
+ ```typescript
14129
+ public readonly gitleaksOptions: GitleaksOptions;
14130
+ ```
14131
+
14132
+ - *Type:* <a href="#@taimos/projen.GitleaksOptions">GitleaksOptions</a>
14133
+ - *Default:* extend the default ruleset, no extra allowlists
14134
+
14135
+ Options for the gitleaks component.
14136
+
14137
+ Only used when `gitleaks` is enabled.
14138
+
14139
+ ---
14140
+
13700
14141
  ##### `nodeVersion`<sup>Optional</sup> <a name="nodeVersion" id="@taimos/projen.MonorepoProjectOptions.property.nodeVersion"></a>
13701
14142
 
13702
14143
  ```typescript
@@ -43,7 +43,7 @@ const DEFAULT_SHARED_BUILD_PATHS = [
43
43
  * assume-role or parameter-read step rather than skipping a deploy.
44
44
  */
45
45
  class GitHubAmplifyDeploy extends projen_1.Component {
46
- static [JSII_RTTI_SYMBOL_1] = { fqn: "@taimos/projen.GitHubAmplifyDeploy", version: "0.1.84" };
46
+ static [JSII_RTTI_SYMBOL_1] = { fqn: "@taimos/projen.GitHubAmplifyDeploy", version: "0.1.86" };
47
47
  /** The generated deploy workflows, one per app. */
48
48
  workflows = [];
49
49
  /** Name of the IAM role CI chains into, in every stage account. */
@@ -0,0 +1,69 @@
1
+ import { Component, TextFile, github, typescript } from 'projen';
2
+ /**
3
+ * One path-scoped allowlist entry for the generated `.gitleaks.toml`.
4
+ *
5
+ * Each entry is rendered as a `[[allowlists]]` block. Keep every allowlist as
6
+ * tightly path-scoped as possible so it cannot mask a real secret elsewhere in
7
+ * the repo.
8
+ */
9
+ export interface GitleaksAllowlist {
10
+ /** Human-readable description of what this allowlist exempts and why. */
11
+ readonly description: string;
12
+ /**
13
+ * Regex paths the allowlist applies to (rendered as gitleaks `paths`), e.g.
14
+ * `['^\\.npmrc$']`. Omit to apply the regexes repo-wide (discouraged).
15
+ *
16
+ * @default - no path scope
17
+ */
18
+ readonly paths?: string[];
19
+ /**
20
+ * Regexes matching the allowed secret values (rendered as gitleaks
21
+ * `regexes`). Omit to allow anything on the scoped paths.
22
+ *
23
+ * @default - no value regexes
24
+ */
25
+ readonly regexes?: string[];
26
+ /**
27
+ * gitleaks `condition` combining `paths` and `regexes` (`AND` requires both).
28
+ *
29
+ * @default - gitleaks default (OR)
30
+ */
31
+ readonly condition?: string;
32
+ /**
33
+ * gitleaks `regexTarget` (`secret` | `match` | `line`).
34
+ *
35
+ * @default - gitleaks default
36
+ */
37
+ readonly regexTarget?: string;
38
+ }
39
+ export interface GitleaksOptions {
40
+ /**
41
+ * The gitleaks version downloaded in CI.
42
+ *
43
+ * @default '8.30.1'
44
+ */
45
+ readonly version?: string;
46
+ /**
47
+ * Path-scoped allowlists for known false positives, appended after
48
+ * `[extend] useDefault = true`.
49
+ *
50
+ * @default []
51
+ */
52
+ readonly allowlists?: GitleaksAllowlist[];
53
+ }
54
+ /**
55
+ * gitleaks secret-scanning for a project: a `.gitleaks.toml` config that extends
56
+ * the bundled default ruleset plus tightly path-scoped allowlists, and a
57
+ * pull-request workflow that scans the full git history against it.
58
+ *
59
+ * projen has no native gitleaks component, so both artifacts are generated here
60
+ * to stay in the "never hand-edit generated files" model. Requires GitHub to be
61
+ * enabled on the project.
62
+ */
63
+ export declare class Gitleaks extends Component {
64
+ /** The generated `.gitleaks.toml`. */
65
+ readonly configFile: TextFile;
66
+ /** The generated pull-request scanning workflow. */
67
+ readonly workflow: github.GithubWorkflow;
68
+ constructor(scope: typescript.TypeScriptProject, options?: GitleaksOptions);
69
+ }
@@ -0,0 +1,93 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Gitleaks = void 0;
4
+ const JSII_RTTI_SYMBOL_1 = Symbol.for("jsii.rtti");
5
+ const projen_1 = require("projen");
6
+ /**
7
+ * gitleaks secret-scanning for a project: a `.gitleaks.toml` config that extends
8
+ * the bundled default ruleset plus tightly path-scoped allowlists, and a
9
+ * pull-request workflow that scans the full git history against it.
10
+ *
11
+ * projen has no native gitleaks component, so both artifacts are generated here
12
+ * to stay in the "never hand-edit generated files" model. Requires GitHub to be
13
+ * enabled on the project.
14
+ */
15
+ class Gitleaks extends projen_1.Component {
16
+ static [JSII_RTTI_SYMBOL_1] = { fqn: "@taimos/projen.Gitleaks", version: "0.1.86" };
17
+ /** The generated `.gitleaks.toml`. */
18
+ configFile;
19
+ /** The generated pull-request scanning workflow. */
20
+ workflow;
21
+ constructor(scope, options = {}) {
22
+ super(scope);
23
+ if (!scope.github) {
24
+ throw new Error('Gitleaks requires GitHub to be enabled on the project');
25
+ }
26
+ const version = options.version ?? '8.30.1';
27
+ const allowlists = options.allowlists ?? [];
28
+ const lines = [
29
+ '# ~~ Generated by projen. To modify, edit .projenrc.ts and run "npx projen".',
30
+ '#',
31
+ '# gitleaks config. Extends the default ruleset, then adds tightly scoped',
32
+ '# allowlists for known false positives. Each allowlist is path-scoped so it',
33
+ '# cannot mask a real secret elsewhere in the repo.',
34
+ '[extend]',
35
+ 'useDefault = true',
36
+ ];
37
+ for (const a of allowlists) {
38
+ lines.push('', `# ${a.description}`, '[[allowlists]]', `description = ${JSON.stringify(a.description)}`);
39
+ if (a.condition) {
40
+ lines.push(`condition = ${JSON.stringify(a.condition)}`);
41
+ }
42
+ if (a.regexTarget) {
43
+ lines.push(`regexTarget = ${JSON.stringify(a.regexTarget)}`);
44
+ }
45
+ if (a.paths && a.paths.length > 0) {
46
+ lines.push(`paths = [${a.paths.map((p) => `'''${p}'''`).join(', ')}]`);
47
+ }
48
+ if (a.regexes && a.regexes.length > 0) {
49
+ lines.push(`regexes = [${a.regexes.map((r) => `'''${r}'''`).join(', ')}]`);
50
+ }
51
+ }
52
+ this.configFile = new projen_1.TextFile(scope, '.gitleaks.toml', {
53
+ lines,
54
+ // A `//`-style projen marker is invalid TOML; the `#` marker is baked in.
55
+ marker: false,
56
+ });
57
+ this.workflow = scope.github.addWorkflow('gitleaks');
58
+ // Secrets can land in any path, so no path filter — plus merge queue and
59
+ // manual dispatch, matching the repo's other workflows.
60
+ this.workflow.on({
61
+ pullRequest: {},
62
+ mergeGroup: {},
63
+ workflowDispatch: {},
64
+ });
65
+ this.workflow.addJob('gitleaks', {
66
+ runsOn: ['ubuntu-latest'],
67
+ permissions: { contents: projen_1.github.workflows.JobPermission.READ },
68
+ steps: [
69
+ {
70
+ name: 'Checkout',
71
+ uses: 'actions/checkout@v4',
72
+ // Full history so gitleaks scans every commit in the PR, not just HEAD.
73
+ with: { 'fetch-depth': 0 },
74
+ },
75
+ {
76
+ name: 'Install gitleaks',
77
+ run: [
78
+ `curl -sSfL https://github.com/gitleaks/gitleaks/releases/download/v${version}/gitleaks_${version}_linux_x64.tar.gz \\`,
79
+ ' | tar -xz gitleaks',
80
+ 'sudo mv gitleaks /usr/local/bin/gitleaks',
81
+ ].join('\n'),
82
+ },
83
+ {
84
+ name: 'Scan git history',
85
+ // --redact keeps any real secret out of the public CI logs.
86
+ run: 'gitleaks git --no-banner --redact .',
87
+ },
88
+ ],
89
+ });
90
+ }
91
+ }
92
+ exports.Gitleaks = Gitleaks;
93
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2l0bGVha3MuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi9zcmMvY29tcG9uZW50cy9naXRsZWFrcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7O0FBQUEsbUNBQWlFO0FBd0RqRTs7Ozs7Ozs7R0FRRztBQUNILE1BQWEsUUFBUyxTQUFRLGtCQUFTOztJQUVyQyxzQ0FBc0M7SUFDdEIsVUFBVSxDQUFXO0lBRXJDLG9EQUFvRDtJQUNwQyxRQUFRLENBQXdCO0lBRWhELFlBQVksS0FBbUMsRUFBRSxVQUEyQixFQUFFO1FBQzVFLEtBQUssQ0FBQyxLQUFLLENBQUMsQ0FBQztRQUViLElBQUksQ0FBQyxLQUFLLENBQUMsTUFBTSxFQUFFLENBQUM7WUFDbEIsTUFBTSxJQUFJLEtBQUssQ0FBQyx1REFBdUQsQ0FBQyxDQUFDO1FBQzNFLENBQUM7UUFFRCxNQUFNLE9BQU8sR0FBRyxPQUFPLENBQUMsT0FBTyxJQUFJLFFBQVEsQ0FBQztRQUM1QyxNQUFNLFVBQVUsR0FBRyxPQUFPLENBQUMsVUFBVSxJQUFJLEVBQUUsQ0FB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ICAgIHdpdGg6IHsgJ2ZldGNoLWRlcHRoJzogMCB9LFxuICAgICAgICB9LFxuICAgICAgICB7XG4gICAgICAgICAgbmFtZTogJ0luc3RhbGwgZ2l0bGVha3MnLFxuICAgICAgICAgIHJ1bjogW1xuICAgICAgICAgICAgYGN1cmwgLXNTZkwgaHR0cHM6Ly9naXRodWIuY29tL2dpdGxlYWtzL2dpdGxlYWtzL3JlbGVhc2VzL2Rvd25sb2FkL3Yke3ZlcnNpb259L2dpdGxlYWtzXyR7dmVyc2lvbn1fbGludXhfeDY0LnRhci5neiBcXFxcYCxcbiAgICAgICAgICAgICcgIHwgdGFyIC14eiBnaXRsZWFrcycsXG4gICAgICAgICAgICAnc3VkbyBtdiBnaXRsZWFrcyAvdXNyL2xvY2FsL2Jpbi9naXRsZWFrcycsXG4gICAgICAgICAgXS5qb2luKCdcXG4nKSxcbiAgICAgICAgfSxcbiAgICAgICAge1xuICAgICAgICAgIG5hbWU6ICdTY2FuIGdpdCBoaXN0b3J5JyxcbiAgICAgICAgICAvLyAtLXJlZGFjdCBrZWVwcyBhbnkgcmVhbCBzZWNyZXQgb3V0IG9mIHRoZSBwdWJsaWMgQ0kgbG9ncy5cbiAgICAgICAgICBydW46ICdnaXRsZWFrcyBnaXQgLS1uby1iYW5uZXIgLS1yZWRhY3QgLicsXG4gICAgICAgIH0sXG4gICAgICBdLFxuICAgIH0pO1xuICB9XG59XG4iXX0=
@@ -1,2 +1,3 @@
1
1
  export * from './amplify-deploy';
2
2
  export * from './production-release';
3
+ export * from './gitleaks';