Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

You can't use selective deployment with wildcard service chaining #1415

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion content/spin/v3/http-outbound.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,12 +218,14 @@ You must still grant permission by including the relevant `spin.internal` hosts
allowed_outbound_hosts = ["http://authz.spin.internal", "https://reporting.spin.internal"]
```

To allow local chaining to _any_ component in your application, use a subdomain wildcard:
To allow local chaining to _any_ component in your application, you can use a subdomain wildcard:

```toml
allowed_outbound_hosts = ["http://*.spin.internal"]
```

However, the wildcard implies that the component requires _all other_ components to be local to it. You will therefore not be able to use [selective deployment](./running-apps#splitting-an-application-across-environments) for an application that uses wildcard service chaining.

> Local service chaining is not currently supported on Fermyon Cloud.

### Intra-Application HTTP Requests by Route
Expand Down
2 changes: 1 addition & 1 deletion content/spin/v3/running-apps.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ $ spin up -f registry.example.com/app:1.1.0 -c chat-engine -c sentiment-analyzer

> In practice you'd set these commands up in a scheduler or orchestrator rather than typing them interactively - or, more likely, use a selection-aware scheduler such as [SpinKube](https://www.spinkube.dev/) rather than running `spin up` directly.

If you run a subset which includes a component that uses [local service chaining](./http-outbound#local-service-chaining), then you must also include all chaining targets in the subset - Spin checks this at load time. [Self-requests](./http-outbound#making-http-requests-within-an-application) will work only if the target route maps to a component in the subset, but this is not checked at load time - instead, self-requests to unselected components will fail at request time with 404 Not Found.
If you run a subset which includes a component that uses [local service chaining](./http-outbound#local-service-chaining), then you must also include all chaining targets in the subset - Spin checks this at load time. (Wildcard service chaining - the `*.spin.internal` host - means that _all_ components are potential chaining targets, so you will not be able to use selective deployment if any component uses wildcard service chaining.) [Self-requests](./http-outbound#making-http-requests-within-an-application) will work only if the target route maps to a component in the subset, but this is not checked at load time - instead, self-requests to unselected components will fail at request time with 404 Not Found.

## The Always Build Option

Expand Down
Loading