Browse Source

CONNECTIONSTRING comes as CONNECTIONSTRINGS (#843)

CONNECTIONSTRING comes as CONNECTIONSTRINGS in the environment variable.
(Discovery during debugging tye run --debug (code is .NET 5.0.100) via System.Environment.GetEnvironmentVariable

CONNECTIONSTRING__POSTGRES -> CONNECTIONSTRINGS__POSTGRES
pull/848/head
Habib Ahmed Qureshi 6 years ago
committed by GitHub
parent
commit
3321542a97
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      docs/reference/service_discovery.md

4
docs/reference/service_discovery.md

@ -193,14 +193,14 @@ The pattern for a default binding on the `postgres` service:
| | Environment Variable | Configuration Key |
|-------------------|------------------------------|----------------------------|
| Connection String | `CONNECTIONSTRING__POSTGRES` | `connectionstrings:postgres` |
| Connection String | `CONNECTIONSTRINGS__POSTGRES` | `connectionstrings:postgres` |
The pattern for a named binding called `myBinding` on the `postgres` service:
| | Environment Variable | Configuration Key |
|-------------------|------------------------------|----------------------------|
| Connection String | `CONNECTIONSTRING__POSTGRES__MYBINDING` | `connectionstrings:postgres:mybinding` |
| Connection String | `CONNECTIONSTRINGS__POSTGRES__MYBINDING` | `connectionstrings:postgres:mybinding` |
> :bulb: That's a double-underscore (`__`) in the environment variables. The `Microsoft.Extensions.Configuration` system uses double-underscore as a separator because single underscores are already common in environment variables.

Loading…
Cancel
Save