@vinext/cloudflare 1.0.0-beta.6 → 1.0.0-beta.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/README.md +17 -0
- package/dist/cache/cdn-adapter-config.d.ts +22 -0
- package/dist/cache/cdn-adapter-config.js +47 -0
- package/dist/cache/cdn-adapter.d.ts +34 -3
- package/dist/cache/cdn-adapter.js +34 -2
- package/dist/cache/cdn-adapter.runtime.d.ts +17 -1
- package/dist/cache/cdn-adapter.runtime.js +80 -5
- package/dist/cache/cdn-build-id.d.ts +5 -0
- package/dist/cache/cdn-build-id.js +5 -0
- package/dist/cache/kv-data-adapter.runtime.js +1 -1
- package/dist/cacheability-artifact.d.ts +10 -0
- package/dist/cacheability-artifact.js +165 -0
- package/dist/cacheability-manifest-limits.d.ts +5 -0
- package/dist/cacheability-manifest-limits.js +7 -0
- package/dist/cacheability-probe.d.ts +50 -0
- package/dist/cacheability-probe.js +496 -0
- package/dist/cdn-warm.d.ts +95 -2
- package/dist/cdn-warm.js +704 -80
- package/dist/cli.js +15 -1
- package/dist/deploy-config.d.ts +5 -1
- package/dist/deploy-config.js +15 -2
- package/dist/deploy-help.js +43 -6
- package/dist/deploy.d.ts +61 -6
- package/dist/deploy.js +631 -82
- package/dist/prerender-kv-populate.js +1 -1
- package/dist/tpr.js +2 -2
- package/dist/version-deploy.d.ts +12 -9
- package/dist/version-deploy.js +24 -10
- package/dist/version-headers.d.ts +2 -0
- package/dist/version-headers.js +2 -0
- package/dist/worker-deployment-url.d.ts +7 -1
- package/dist/worker-deployment-url.js +23 -1
- package/dist/wrangler-version-metadata.d.ts +8 -0
- package/dist/wrangler-version-metadata.js +9 -0
- package/package.json +4 -3
package/dist/cli.js
CHANGED
|
@@ -38,16 +38,30 @@ async function deployCommand() {
|
|
|
38
38
|
root: process.cwd(),
|
|
39
39
|
preview: parsed.preview,
|
|
40
40
|
env: parsed.env,
|
|
41
|
+
config: parsed.config,
|
|
41
42
|
skipBuild: parsed.skipBuild,
|
|
42
43
|
dryRun: parsed.dryRun,
|
|
44
|
+
verbose: parsed.verbose,
|
|
43
45
|
name: parsed.name,
|
|
44
46
|
prerenderAll: parsed.prerenderAll,
|
|
45
47
|
prerenderConcurrency: parsed.prerenderConcurrency,
|
|
46
48
|
warmCdnCache: parsed.warmCdnCache,
|
|
49
|
+
warmCdnTarget: parsed.warmCdnTarget,
|
|
47
50
|
warmCdnConcurrency: parsed.warmCdnConcurrency,
|
|
48
51
|
warmCdnTimeout: parsed.warmCdnTimeout,
|
|
49
52
|
warmCdnRetries: parsed.warmCdnRetries,
|
|
50
|
-
|
|
53
|
+
warmCdnDiscoveryTimeout: parsed.warmCdnDiscoveryTimeout,
|
|
54
|
+
warmCdnDiscoveryRetries: parsed.warmCdnDiscoveryRetries,
|
|
55
|
+
warmCdnProbeTimeout: parsed.warmCdnProbeTimeout,
|
|
56
|
+
warmCdnProbeRetries: parsed.warmCdnProbeRetries,
|
|
57
|
+
warmCdnCertify: parsed.warmCdnCertify,
|
|
58
|
+
warmCdnReadinessTimeout: parsed.warmCdnReadinessTimeout,
|
|
59
|
+
warmCdnReadinessRetries: parsed.warmCdnReadinessRetries,
|
|
60
|
+
warmCdnReadinessProbes: parsed.warmCdnReadinessProbes,
|
|
61
|
+
warmCdnReadinessProbeDelay: parsed.warmCdnReadinessProbeDelay,
|
|
62
|
+
dangerouslyPromoteOnCdnWarmError: parsed.dangerouslyPromoteOnCdnWarmError,
|
|
63
|
+
warmCdnPromote: parsed.warmCdnPromote,
|
|
64
|
+
warmCdnPromotionDelay: parsed.warmCdnPromotionDelay,
|
|
51
65
|
warmCdnIncludeFallbacks: parsed.warmCdnIncludeFallbacks,
|
|
52
66
|
experimentalTPR: parsed.experimentalTPR,
|
|
53
67
|
tprCoverage: parsed.tprCoverage,
|
package/dist/deploy-config.d.ts
CHANGED
|
@@ -23,6 +23,10 @@ type ResolvedKvDataAdapterConfig = {
|
|
|
23
23
|
appPrefix?: string;
|
|
24
24
|
ttlSeconds?: number;
|
|
25
25
|
};
|
|
26
|
+
type ResolvedCdnAdapterConfig = {
|
|
27
|
+
versionMetadataBinding: string;
|
|
28
|
+
};
|
|
29
|
+
declare function resolveCdnAdapterConfig(cache: VinextCacheConfig | null | undefined): ResolvedCdnAdapterConfig | null;
|
|
26
30
|
declare function resolveKvDataAdapterConfig(cache: VinextCacheConfig | null | undefined): ResolvedKvDataAdapterConfig | null;
|
|
27
31
|
declare function viteConfigHasImageAdapter(root: string): boolean;
|
|
28
32
|
/**
|
|
@@ -51,4 +55,4 @@ declare function formatMissingCacheAdapterError(options: {
|
|
|
51
55
|
}): string;
|
|
52
56
|
declare function formatImageOptimizationHint(): string;
|
|
53
57
|
//#endregion
|
|
54
|
-
export { ResolvedKvDataAdapterConfig, formatImageOptimizationHint, formatMissingCacheAdapterError, resolveKvDataAdapterConfig, viteConfigHasCacheAdapter, viteConfigHasCloudflarePlugin, viteConfigHasImageAdapter, workerEntryHasCacheHandler };
|
|
58
|
+
export { ResolvedCdnAdapterConfig, ResolvedKvDataAdapterConfig, formatImageOptimizationHint, formatMissingCacheAdapterError, resolveCdnAdapterConfig, resolveKvDataAdapterConfig, viteConfigHasCacheAdapter, viteConfigHasCloudflarePlugin, viteConfigHasImageAdapter, workerEntryHasCacheHandler };
|
package/dist/deploy-config.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { DEFAULT_KV_DATA_CACHE_BINDING } from "./cache/kv-data-adapter.js";
|
|
2
|
-
import
|
|
2
|
+
import { DEFAULT_CDN_VERSION_METADATA_BINDING } from "./cache/cdn-adapter.js";
|
|
3
3
|
import fs from "node:fs";
|
|
4
|
+
import path from "node:path";
|
|
5
|
+
import { fileURLToPath } from "node:url";
|
|
4
6
|
import { findViteConfigPath } from "vinext/internal/utils/project";
|
|
5
7
|
//#region src/deploy-config.ts
|
|
6
8
|
function escapeRegExp(value) {
|
|
@@ -87,6 +89,17 @@ function viteConfigHasCacheAdapter(root) {
|
|
|
87
89
|
if (!block) return false;
|
|
88
90
|
return cacheFieldAssigned(block, "cdn") || cacheFieldAssigned(block, "data");
|
|
89
91
|
}
|
|
92
|
+
function isCloudflareCdnAdapterPath(adapter) {
|
|
93
|
+
const normalized = adapter.replace(/\\/g, "/");
|
|
94
|
+
const bundledRuntime = fileURLToPath(new URL("./cache/cdn-adapter.runtime.js", import.meta.url)).replace(/\\/g, "/");
|
|
95
|
+
return normalized === "@vinext/cloudflare/cache/cdn-adapter.runtime" || normalized === "@vinext/cloudflare/cache/cdn-adapter.runtime.js" || normalized === bundledRuntime;
|
|
96
|
+
}
|
|
97
|
+
function resolveCdnAdapterConfig(cache) {
|
|
98
|
+
const cdn = cache?.cdn;
|
|
99
|
+
if (!cdn?.adapter || !isCloudflareCdnAdapterPath(cdn.adapter)) return null;
|
|
100
|
+
const options = cdn.options;
|
|
101
|
+
return { versionMetadataBinding: typeof options?.versionMetadataBinding === "string" && options.versionMetadataBinding.length > 0 ? options.versionMetadataBinding : DEFAULT_CDN_VERSION_METADATA_BINDING };
|
|
102
|
+
}
|
|
90
103
|
function isCloudflareKvDataAdapterPath(adapter) {
|
|
91
104
|
const normalized = adapter.replace(/\\/g, "/");
|
|
92
105
|
return normalized === "@vinext/cloudflare/cache/kv-data-adapter.runtime" || normalized === "@vinext/cloudflare/cache/kv-data-adapter.runtime.js" || normalized.endsWith("/cache/kv-data-adapter.runtime.js");
|
|
@@ -166,4 +179,4 @@ function formatImageOptimizationHint() {
|
|
|
166
179
|
return " [vinext] next/image is served unoptimized. To enable edge image\n optimization via Cloudflare Images, run:\n\n vinext init --platform=cloudflare --image-optimization=cloudflare-images\n\n This adds the imagesOptimizer() option to your Vite config and the matching\n IMAGES binding to your Wrangler config without replacing existing settings.";
|
|
167
180
|
}
|
|
168
181
|
//#endregion
|
|
169
|
-
export { formatImageOptimizationHint, formatMissingCacheAdapterError, resolveKvDataAdapterConfig, viteConfigHasCacheAdapter, viteConfigHasCloudflarePlugin, viteConfigHasImageAdapter, workerEntryHasCacheHandler };
|
|
182
|
+
export { formatImageOptimizationHint, formatMissingCacheAdapterError, resolveCdnAdapterConfig, resolveKvDataAdapterConfig, viteConfigHasCacheAdapter, viteConfigHasCloudflarePlugin, viteConfigHasImageAdapter, workerEntryHasCacheHandler };
|
package/dist/deploy-help.js
CHANGED
|
@@ -18,6 +18,7 @@ function formatDeployHelp() {
|
|
|
18
18
|
--config <path> Wrangler config path (default: wrangler.jsonc/json/toml)
|
|
19
19
|
--skip-build Skip the build step (use existing dist/)
|
|
20
20
|
--dry-run Validate setup without building or deploying
|
|
21
|
+
--verbose Print raw output from internal Wrangler commands
|
|
21
22
|
--prerender-all Pre-render discovered routes after building (future
|
|
22
23
|
releases will auto-populate the remote cache)
|
|
23
24
|
--prerender-concurrency <count>
|
|
@@ -25,11 +26,44 @@ function formatDeployHelp() {
|
|
|
25
26
|
--experimental-warm-cdn-cache
|
|
26
27
|
Upload a Worker version, warm build-discovered paths
|
|
27
28
|
through the production URL, then promote it (experimental)
|
|
29
|
+
--warm-cdn-target <origin>
|
|
30
|
+
HTTPS origin to use for discovery, probing, and warming
|
|
31
|
+
(overrides URLs inferred from Wrangler output)
|
|
28
32
|
--warm-cdn-concurrency <count>
|
|
29
|
-
Maximum number of CDN warmup requests in parallel
|
|
30
|
-
--warm-cdn-timeout <ms> Per-request CDN warmup timeout (default:
|
|
31
|
-
--warm-cdn-retries <n> Retries
|
|
32
|
-
|
|
33
|
+
Maximum number of CDN warmup requests in parallel (default: 25)
|
|
34
|
+
--warm-cdn-timeout <ms> Per-request CDN warmup timeout (default: 10000)
|
|
35
|
+
--warm-cdn-retries <n> Retries per failed CDN warmup request (default: 1;
|
|
36
|
+
staged-version propagation default: 60)
|
|
37
|
+
--warm-cdn-discovery-timeout <ms>
|
|
38
|
+
Total staged path-discovery deadline (default: 120000)
|
|
39
|
+
--warm-cdn-discovery-retries <n>
|
|
40
|
+
Optional staged path-discovery retry limit
|
|
41
|
+
(default: derived from the discovery deadline)
|
|
42
|
+
--warm-cdn-probe-timeout <ms>
|
|
43
|
+
Abort when cacheability probing makes no progress for
|
|
44
|
+
this duration (default: 120000)
|
|
45
|
+
--warm-cdn-probe-retries <n>
|
|
46
|
+
Cacheability-probe retries (default: 2)
|
|
47
|
+
--warm-cdn-certify With --experimental-warm-cdn-cache, re-request warmed
|
|
48
|
+
entries using headers only and require every planned
|
|
49
|
+
entry to be reusable before promotion
|
|
50
|
+
--warm-cdn-readiness-timeout <ms>
|
|
51
|
+
Explicit total staged-readiness deadline (default:
|
|
52
|
+
120000)
|
|
53
|
+
--warm-cdn-readiness-retries <n>
|
|
54
|
+
Staged-readiness retries (default: 60)
|
|
55
|
+
--warm-cdn-readiness-probes <count>
|
|
56
|
+
Consecutive successful staged-readiness probes
|
|
57
|
+
required before warming (default: 6)
|
|
58
|
+
--warm-cdn-readiness-probe-delay <ms>
|
|
59
|
+
Delay between staged-readiness probes (default: 1000)
|
|
60
|
+
--dangerously-promote-on-cdn-warm-error
|
|
61
|
+
Promote even when ordinary staged warmup cannot be
|
|
62
|
+
verified (never bypasses --warm-cdn-certify)
|
|
63
|
+
--warm-cdn-no-promote Leave the warmed Worker version staged at 0% traffic;
|
|
64
|
+
production triggers are still applied before warming
|
|
65
|
+
--warm-cdn-promotion-delay <ms>
|
|
66
|
+
Delay before promotion after warmup (default: 15000)
|
|
33
67
|
--warm-cdn-include-fallbacks
|
|
34
68
|
Also warm PPR fallback-shell placeholder paths
|
|
35
69
|
-h, --help Show this help
|
|
@@ -46,8 +80,9 @@ function formatDeployHelp() {
|
|
|
46
80
|
a custom domain (zone analytics are unavailable on *.workers.dev) and the
|
|
47
81
|
CLOUDFLARE_API_TOKEN environment variable with Zone.Analytics read permission.
|
|
48
82
|
|
|
49
|
-
|
|
50
|
-
|
|
83
|
+
Workers Cache automatically uses tiered caching. Warmed entries can therefore
|
|
84
|
+
be reused outside the data center reached by the warmup request after cache
|
|
85
|
+
propagation, but the deploy does not wait for every edge location to fill.
|
|
51
86
|
|
|
52
87
|
Examples:
|
|
53
88
|
npx @vinext/cloudflare deploy Build and deploy to production
|
|
@@ -59,6 +94,8 @@ function formatDeployHelp() {
|
|
|
59
94
|
vinext-cloudflare deploy --dry-run Validate setup without building or deploying
|
|
60
95
|
vinext-cloudflare deploy --name my-app Deploy with a custom Worker name
|
|
61
96
|
vinext-cloudflare deploy --experimental-warm-cdn-cache Warm build-discovered paths during version deploy (experimental)
|
|
97
|
+
vinext-cloudflare deploy --experimental-warm-cdn-cache --warm-cdn-target https://example.com
|
|
98
|
+
Warm an explicit production origin
|
|
62
99
|
vinext-cloudflare deploy --experimental-tpr Enable TPR during deploy
|
|
63
100
|
vinext-cloudflare deploy --experimental-tpr --tpr-coverage 95 Cover 95% of traffic
|
|
64
101
|
vinext-cloudflare deploy --experimental-tpr --tpr-limit 500 Cap at 500 pages
|
package/dist/deploy.d.ts
CHANGED
|
@@ -1,8 +1,12 @@
|
|
|
1
|
+
import { CdnWarmOptions, CdnWarmRequestPlan, PrerenderWarmPlan } from "./cdn-warm.js";
|
|
1
2
|
import { parseWranglerConfig } from "./tpr.js";
|
|
2
3
|
import { WranglerDeploymentStatus, WranglerVersionTraffic } from "./version-deploy.js";
|
|
3
4
|
import { KVBulkPair } from "./prerender-kv-populate.js";
|
|
4
5
|
import { spawn } from "node:child_process";
|
|
6
|
+
import { VinextCacheConfig } from "vinext/internal/config/prerender";
|
|
7
|
+
import { ProjectInfo } from "vinext/internal/utils/project";
|
|
5
8
|
//#region src/deploy.d.ts
|
|
9
|
+
declare const DEFAULT_CDN_WARM_PROMOTION_DELAY_MS = 15000;
|
|
6
10
|
type DeployOptions = {
|
|
7
11
|
/** Project root directory */
|
|
8
12
|
root: string;
|
|
@@ -18,20 +22,46 @@ type DeployOptions = {
|
|
|
18
22
|
skipBuild?: boolean;
|
|
19
23
|
/** Dry run — validate setup but don't build or deploy */
|
|
20
24
|
dryRun?: boolean;
|
|
25
|
+
/** Print raw output from internal Wrangler commands. */
|
|
26
|
+
verbose?: boolean;
|
|
21
27
|
/** Pre-render all discovered routes into the dist output after building */
|
|
22
28
|
prerenderAll?: boolean;
|
|
23
29
|
/** Maximum number of routes to prerender in parallel */
|
|
24
30
|
prerenderConcurrency?: number;
|
|
25
31
|
/** Warm Cloudflare's CDN cache by requesting build-discovered paths for the uploaded version */
|
|
26
32
|
warmCdnCache?: boolean;
|
|
33
|
+
/** Explicit production origin to use for CDN discovery, probing, and warming */
|
|
34
|
+
warmCdnTarget?: string;
|
|
27
35
|
/** Maximum number of CDN warmup requests to issue in parallel */
|
|
28
36
|
warmCdnConcurrency?: number;
|
|
29
37
|
/** Per-request CDN warmup timeout in milliseconds */
|
|
30
38
|
warmCdnTimeout?: number;
|
|
31
39
|
/** Number of CDN warmup retries for transient failures */
|
|
32
40
|
warmCdnRetries?: number;
|
|
33
|
-
/**
|
|
34
|
-
|
|
41
|
+
/** Maximum duration of staged Worker path discovery */
|
|
42
|
+
warmCdnDiscoveryTimeout?: number;
|
|
43
|
+
/** Number of transient staged Worker path discovery retries */
|
|
44
|
+
warmCdnDiscoveryRetries?: number;
|
|
45
|
+
/** Abort after this duration without a completed cacheability probe */
|
|
46
|
+
warmCdnProbeTimeout?: number;
|
|
47
|
+
/** Number of transient staged Worker cacheability probe retries */
|
|
48
|
+
warmCdnProbeRetries?: number;
|
|
49
|
+
/** Re-request warmed identities and require reusable CDN hits before promotion */
|
|
50
|
+
warmCdnCertify?: boolean;
|
|
51
|
+
/** Maximum duration of staged Worker readiness verification */
|
|
52
|
+
warmCdnReadinessTimeout?: number;
|
|
53
|
+
/** Number of staged Worker readiness retries */
|
|
54
|
+
warmCdnReadinessRetries?: number;
|
|
55
|
+
/** Consecutive successful probes required before warming the staged Worker */
|
|
56
|
+
warmCdnReadinessProbes?: number;
|
|
57
|
+
/** Delay between staged Worker readiness probes in milliseconds */
|
|
58
|
+
warmCdnReadinessProbeDelay?: number;
|
|
59
|
+
/** Promote even when staged CDN warmup cannot be completed */
|
|
60
|
+
dangerouslyPromoteOnCdnWarmError?: boolean;
|
|
61
|
+
/** Promote the warmed Worker version to 100% traffic (default: true) */
|
|
62
|
+
warmCdnPromote?: boolean;
|
|
63
|
+
/** Delay between successful warmup and promotion in milliseconds */
|
|
64
|
+
warmCdnPromotionDelay?: number;
|
|
35
65
|
/** Include PPR fallback-shell placeholder paths during CDN warmup */
|
|
36
66
|
warmCdnIncludeFallbacks?: boolean;
|
|
37
67
|
/** Enable experimental TPR (Traffic-aware Pre-Rendering) */
|
|
@@ -51,13 +81,26 @@ declare function parseDeployArgs(args: string[]): {
|
|
|
51
81
|
config: string | undefined;
|
|
52
82
|
skipBuild: boolean;
|
|
53
83
|
dryRun: boolean;
|
|
84
|
+
verbose: boolean;
|
|
54
85
|
prerenderAll: boolean;
|
|
55
86
|
prerenderConcurrency: number | undefined;
|
|
56
87
|
warmCdnCache: boolean;
|
|
88
|
+
warmCdnTarget: string | undefined;
|
|
57
89
|
warmCdnConcurrency: number | undefined;
|
|
58
90
|
warmCdnTimeout: number | undefined;
|
|
59
91
|
warmCdnRetries: number | undefined;
|
|
60
|
-
|
|
92
|
+
warmCdnDiscoveryTimeout: number | undefined;
|
|
93
|
+
warmCdnDiscoveryRetries: number | undefined;
|
|
94
|
+
warmCdnProbeTimeout: number | undefined;
|
|
95
|
+
warmCdnProbeRetries: number | undefined;
|
|
96
|
+
warmCdnCertify: boolean;
|
|
97
|
+
warmCdnReadinessTimeout: number | undefined;
|
|
98
|
+
warmCdnReadinessRetries: number | undefined;
|
|
99
|
+
warmCdnReadinessProbes: number | undefined;
|
|
100
|
+
warmCdnReadinessProbeDelay: number | undefined;
|
|
101
|
+
dangerouslyPromoteOnCdnWarmError: boolean;
|
|
102
|
+
warmCdnPromote: boolean;
|
|
103
|
+
warmCdnPromotionDelay: number | undefined;
|
|
61
104
|
warmCdnIncludeFallbacks: boolean;
|
|
62
105
|
experimentalTPR: boolean;
|
|
63
106
|
tprCoverage: number | undefined;
|
|
@@ -115,13 +158,25 @@ declare function runWranglerKVBulkPut(root: string, options: {
|
|
|
115
158
|
tempDir?: string;
|
|
116
159
|
}, execute?: typeof spawn, nodeExecutable?: string): Promise<void>;
|
|
117
160
|
declare function runWranglerDeploy(root: string, options: Pick<DeployOptions, "preview" | "env" | "name" | "config">, execute?: typeof spawn): Promise<string>;
|
|
118
|
-
declare function
|
|
161
|
+
declare function hasCdnWarmRequests(plan: Omit<CdnWarmRequestPlan, "pagesDataPaths"> & {
|
|
162
|
+
pagesDataPaths?: readonly string[];
|
|
163
|
+
}): boolean;
|
|
164
|
+
declare function projectRequiresRouteCacheabilityProbeManifest(project: Pick<ProjectInfo, "isAppRouter" | "isPagesRouter">, cacheConfig: VinextCacheConfig | null): boolean;
|
|
165
|
+
type CdnWarmDeployOptions = Pick<DeployOptions, "preview" | "env" | "name" | "config" | "verbose" | "warmCdnTarget" | "warmCdnConcurrency" | "warmCdnTimeout" | "warmCdnRetries" | "warmCdnDiscoveryTimeout" | "warmCdnDiscoveryRetries" | "warmCdnProbeTimeout" | "warmCdnProbeRetries" | "warmCdnCertify" | "warmCdnReadinessTimeout" | "warmCdnReadinessRetries" | "warmCdnReadinessProbes" | "warmCdnReadinessProbeDelay" | "dangerouslyPromoteOnCdnWarmError" | "warmCdnPromote" | "warmCdnPromotionDelay"> & Pick<CdnWarmOptions, "deploymentId" | "expectedBuildId" | "expectedRscBuildId" | "loadingShellPaths" | "pagesDataPaths" | "routeHandlerPaths" | "routePatterns" | "rscPaths"> & {
|
|
166
|
+
/** Probe a staged Worker and upload the resulting manifest as a second version. */
|
|
167
|
+
cacheabilityProbe?: boolean;
|
|
168
|
+
discoverWarmPlan?: (target: {
|
|
169
|
+
headers?: HeadersInit;
|
|
170
|
+
targetUrl: string;
|
|
171
|
+
}) => Promise<PrerenderWarmPlan>;
|
|
172
|
+
};
|
|
173
|
+
declare function deployWithCdnWarmup(root: string, paths: readonly string[], options: CdnWarmDeployOptions): Promise<string>;
|
|
119
174
|
declare function resolveCdnWarmupTargetUrl(root: string, deployedUrl: string | null): string | null;
|
|
120
|
-
declare function resolveCdnWarmupTargetUrl(root: string, deployedUrl: string | null, options: Pick<DeployOptions, "preview" | "env" | "config">): string | null;
|
|
175
|
+
declare function resolveCdnWarmupTargetUrl(root: string, deployedUrl: string | null, options: Pick<DeployOptions, "preview" | "env" | "config" | "warmCdnTarget">): string | null;
|
|
121
176
|
declare function getZeroPercentStagingTraffic(deployment: WranglerDeploymentStatus | null, versionId: string): WranglerVersionTraffic[] | null;
|
|
122
177
|
type ParsedWranglerConfig = NonNullable<ReturnType<typeof parseWranglerConfig>>;
|
|
123
178
|
declare function resolveWorkerNameForVersionOverride(config: ParsedWranglerConfig | null, options: Pick<DeployOptions, "preview" | "env" | "name">): string | undefined;
|
|
124
179
|
declare function buildVersionOverrideHeaders(workerName: string | undefined, versionId: string): HeadersInit | undefined;
|
|
125
180
|
declare function deploy(options: DeployOptions): Promise<void>;
|
|
126
181
|
//#endregion
|
|
127
|
-
export { DeployOptions, buildNodeCliInvocation, buildVersionOverrideHeaders, buildWranglerDeployArgs, buildWranglerInvocation, buildWranglerKVBulkPutArgs, deploy, deployWithCdnWarmup, getZeroPercentStagingTraffic, parseDeployArgs, resolveCdnWarmupTargetUrl, resolveWorkerNameForVersionOverride, resolveWranglerBin, runWranglerDeploy, runWranglerKVBulkPut, validateWranglerEnvName, withCloudflareEnv };
|
|
182
|
+
export { DEFAULT_CDN_WARM_PROMOTION_DELAY_MS, DeployOptions, buildNodeCliInvocation, buildVersionOverrideHeaders, buildWranglerDeployArgs, buildWranglerInvocation, buildWranglerKVBulkPutArgs, deploy, deployWithCdnWarmup, getZeroPercentStagingTraffic, hasCdnWarmRequests, parseDeployArgs, projectRequiresRouteCacheabilityProbeManifest, resolveCdnWarmupTargetUrl, resolveWorkerNameForVersionOverride, resolveWranglerBin, runWranglerDeploy, runWranglerKVBulkPut, validateWranglerEnvName, withCloudflareEnv };
|