@stacksjs/ts-cloud 0.5.5 → 0.5.7
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/dist/aws/cloudwatch.d.ts +63 -0
- package/dist/aws/lambda.d.ts +22 -0
- package/dist/aws/rds.d.ts +29 -0
- package/dist/bin/cli.js +772 -805
- package/dist/deploy/serverless-app.d.ts +32 -0
- package/dist/index.js +1984 -1863
- package/package.json +3 -3
|
@@ -28,6 +28,21 @@ export interface ResolvedContext {
|
|
|
28
28
|
artifactBucket: string;
|
|
29
29
|
assetsBucket: string;
|
|
30
30
|
}
|
|
31
|
+
/**
|
|
32
|
+
* Resolve the deployed function names, region, and slug for an environment —
|
|
33
|
+
* shared by the logs/metrics/env/warming CLI commands. Throws if the env has no
|
|
34
|
+
* serverless app configured.
|
|
35
|
+
*/
|
|
36
|
+
export declare function resolveServerlessFunctions(config: CloudConfig, environment: EnvironmentType): {
|
|
37
|
+
region: string;
|
|
38
|
+
slug: string;
|
|
39
|
+
stackName: string;
|
|
40
|
+
functions: {
|
|
41
|
+
http: string;
|
|
42
|
+
queue: string;
|
|
43
|
+
cli: string;
|
|
44
|
+
};
|
|
45
|
+
};
|
|
31
46
|
/**
|
|
32
47
|
* Derive framework env vars (DB/Redis hosts) from the deployed stack outputs so
|
|
33
48
|
* a Laravel app connects to the Aurora/RDS-Proxy/ElastiCache resources the
|
|
@@ -45,6 +60,12 @@ export type CodeSource = {
|
|
|
45
60
|
kind: 'image';
|
|
46
61
|
imageUri: string;
|
|
47
62
|
};
|
|
63
|
+
/**
|
|
64
|
+
* AWS caps the aggregate size of a function's environment variables at 4 KB.
|
|
65
|
+
* Check before the API call so we fail with an actionable message (which vars,
|
|
66
|
+
* how far over) instead of a cryptic `InvalidParameterValueException` mid-deploy.
|
|
67
|
+
*/
|
|
68
|
+
export declare function assertEnvWithinLimit(name: string, env: Record<string, string>): void;
|
|
48
69
|
export declare function deployServerlessApp(config: CloudConfig, environment: EnvironmentType, opts?: DeployServerlessOptions): Promise<void>;
|
|
49
70
|
export declare function redeployServerlessApp(config: CloudConfig, environment: EnvironmentType): Promise<void>;
|
|
50
71
|
export declare function rollbackServerlessApp(config: CloudConfig, environment: EnvironmentType): Promise<void>;
|
|
@@ -58,3 +79,14 @@ export declare function runRemoteCommand(config: CloudConfig, environment: Envir
|
|
|
58
79
|
* whitespace argument parsing.
|
|
59
80
|
*/
|
|
60
81
|
export declare function runDbQuery(config: CloudConfig, environment: EnvironmentType, sql: string): Promise<string>;
|
|
82
|
+
/** Rescale the serverless Aurora cluster's min/max ACU capacity. */
|
|
83
|
+
export declare function scaleServerlessDatabase(config: CloudConfig, environment: EnvironmentType, minCapacity: number, maxCapacity: number): Promise<void>;
|
|
84
|
+
/**
|
|
85
|
+
* Restore the serverless Aurora cluster to a point in time as a NEW cluster
|
|
86
|
+
* (the source is untouched). Returns the new cluster identifier.
|
|
87
|
+
*/
|
|
88
|
+
export declare function restoreServerlessDatabase(config: CloudConfig, environment: EnvironmentType, opts: {
|
|
89
|
+
toTime?: Date;
|
|
90
|
+
latest?: boolean;
|
|
91
|
+
target?: string;
|
|
92
|
+
}): Promise<string>;
|