Skip to content

Commit 2e861c2

Browse files
authored
v3 backport for #10396 (#10398)
* hide and mark `service.environments` as deprecated * more comment on services.service (name) field
1 parent b36783c commit 2e861c2

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

packages/wrangler/src/config/environment.ts

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -691,9 +691,18 @@ export interface EnvironmentNonInheritable {
691691
| {
692692
/** The binding name used to refer to the bound service. */
693693
binding: string;
694-
/** The name of the service. */
694+
/**
695+
* The name of the service.
696+
* To bind to a worker in a specific environment,
697+
* you should use the format `<worker_name>-<environment_name>`.
698+
*/
695699
service: string;
696-
/** The environment of the service (e.g. production, staging, etc). */
700+
/**
701+
* @hidden
702+
* @deprecated you should use `service: <worker_name>-<environment_name>` instead.
703+
* This refers to the deprecated concept of 'service environments'.
704+
* The environment of the service (e.g. production, staging, etc).
705+
*/
697706
environment?: string;
698707
/** Optionally, the entrypoint (named export) of the service to bind to. */
699708
entrypoint?: string;

0 commit comments

Comments
 (0)