@codedrifters/configulator 0.0.454 → 0.0.455
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/lib/index.d.mts +14 -0
- package/lib/index.d.ts +14 -0
- package/lib/index.js +37 -0
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +37 -0
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
package/lib/index.d.mts
CHANGED
|
@@ -9886,6 +9886,20 @@ declare class AwsDeploymentTarget extends Component {
|
|
|
9886
9886
|
*
|
|
9887
9887
|
****************************************************************************/
|
|
9888
9888
|
private configureWatchTask;
|
|
9889
|
+
/*****************************************************************************
|
|
9890
|
+
*
|
|
9891
|
+
* Destroy Tasks
|
|
9892
|
+
*
|
|
9893
|
+
* - If local deploy, add a destroy task.
|
|
9894
|
+
*
|
|
9895
|
+
* Mirrors the deploy task family so `destroyDefaults`, per-account
|
|
9896
|
+
* `destroy` overrides, and a target's `cdkOptions.destroy` all reach a
|
|
9897
|
+
* rendered command. Projen's generic `destroy` passthrough is deliberately
|
|
9898
|
+
* left intact as an ad-hoc escape hatch — unlike the generic `deploy` and
|
|
9899
|
+
* `watch` tasks, it is not reset to a disabled stub.
|
|
9900
|
+
*
|
|
9901
|
+
****************************************************************************/
|
|
9902
|
+
private configureDestroyTask;
|
|
9889
9903
|
}
|
|
9890
9904
|
|
|
9891
9905
|
/*******************************************************************************
|
package/lib/index.d.ts
CHANGED
|
@@ -9935,6 +9935,20 @@ declare class AwsDeploymentTarget extends Component {
|
|
|
9935
9935
|
*
|
|
9936
9936
|
****************************************************************************/
|
|
9937
9937
|
private configureWatchTask;
|
|
9938
|
+
/*****************************************************************************
|
|
9939
|
+
*
|
|
9940
|
+
* Destroy Tasks
|
|
9941
|
+
*
|
|
9942
|
+
* - If local deploy, add a destroy task.
|
|
9943
|
+
*
|
|
9944
|
+
* Mirrors the deploy task family so `destroyDefaults`, per-account
|
|
9945
|
+
* `destroy` overrides, and a target's `cdkOptions.destroy` all reach a
|
|
9946
|
+
* rendered command. Projen's generic `destroy` passthrough is deliberately
|
|
9947
|
+
* left intact as an ad-hoc escape hatch — unlike the generic `deploy` and
|
|
9948
|
+
* `watch` tasks, it is not reset to a disabled stub.
|
|
9949
|
+
*
|
|
9950
|
+
****************************************************************************/
|
|
9951
|
+
private configureDestroyTask;
|
|
9938
9952
|
}
|
|
9939
9953
|
|
|
9940
9954
|
/*******************************************************************************
|
package/lib/index.js
CHANGED
|
@@ -38855,6 +38855,42 @@ var AwsDeploymentTarget = class _AwsDeploymentTarget extends import_projen13.Com
|
|
|
38855
38855
|
);
|
|
38856
38856
|
}
|
|
38857
38857
|
};
|
|
38858
|
+
/*****************************************************************************
|
|
38859
|
+
*
|
|
38860
|
+
* Destroy Tasks
|
|
38861
|
+
*
|
|
38862
|
+
* - If local deploy, add a destroy task.
|
|
38863
|
+
*
|
|
38864
|
+
* Mirrors the deploy task family so `destroyDefaults`, per-account
|
|
38865
|
+
* `destroy` overrides, and a target's `cdkOptions.destroy` all reach a
|
|
38866
|
+
* rendered command. Projen's generic `destroy` passthrough is deliberately
|
|
38867
|
+
* left intact as an ad-hoc escape hatch — unlike the generic `deploy` and
|
|
38868
|
+
* `watch` tasks, it is not reset to a disabled stub.
|
|
38869
|
+
*
|
|
38870
|
+
****************************************************************************/
|
|
38871
|
+
this.configureDestroyTask = () => {
|
|
38872
|
+
if (this.localDeployment) {
|
|
38873
|
+
const taskName = [
|
|
38874
|
+
"destroy",
|
|
38875
|
+
this.awsStageType,
|
|
38876
|
+
this.account,
|
|
38877
|
+
this.region
|
|
38878
|
+
].join(":");
|
|
38879
|
+
const destroyTask = this.project.tasks.addTask(taskName, {
|
|
38880
|
+
env: this.awsDeploymentConfig.env
|
|
38881
|
+
});
|
|
38882
|
+
const destroyOpts = this.awsDeploymentConfig.cdkCli.destroyOptionsFor(this);
|
|
38883
|
+
destroyTask.exec(
|
|
38884
|
+
`cdk ${renderCdkDestroy({
|
|
38885
|
+
...destroyOpts,
|
|
38886
|
+
lookups: false,
|
|
38887
|
+
profile: this.localDeploymentConfig?.profile,
|
|
38888
|
+
app: this.awsDeploymentConfig.cdkOut,
|
|
38889
|
+
stackPatterns: this.localDeploymentConfig?.stackPattern ? [this.localDeploymentConfig.stackPattern] : void 0
|
|
38890
|
+
})}`
|
|
38891
|
+
);
|
|
38892
|
+
}
|
|
38893
|
+
};
|
|
38858
38894
|
this.account = options.account;
|
|
38859
38895
|
this.region = options.region;
|
|
38860
38896
|
this.cdkOptions = options.cdkOptions;
|
|
@@ -38897,6 +38933,7 @@ var AwsDeploymentTarget = class _AwsDeploymentTarget extends import_projen13.Com
|
|
|
38897
38933
|
this.awsDeploymentConfig.awsDeploymentTargets.push(this);
|
|
38898
38934
|
this.configureDeployTask();
|
|
38899
38935
|
this.configureWatchTask();
|
|
38936
|
+
this.configureDestroyTask();
|
|
38900
38937
|
}
|
|
38901
38938
|
/**
|
|
38902
38939
|
* Static method to discovert targets in a project.
|