You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently the following configuration will produce authorization errors when trying to distribute this configuration to multiple systems
cluster {
# set the variable token
TOKEN: abc
authorization {
user: user
password: $TOKEN
}
# use the token variable in a field. The password is evaluated as $TOKEN instead of abc
nats://user:$TOKEN@server.example.com:6222,
nats://user:$TOKEN@server2.example.com:6222
}
### Proposal
Allow a way for variables to be interpolated in right hand side of strings
Use case
When distributing configuration across multiple systems via an NFS mount, it makes it easier to map configuration across variables.
Since authentication in a cluster is done in the URL, you must explicitly define the password in the URL. This also disables the ability to define authentication tokens in environment variables
Contribution
No response
The text was updated successfully, but these errors were encountered:
I would suggest the syntax ${TOKEN} as it is pretty common. I would be surprised if there are NATS configs in the wild that are using this syntax but expecting that to be treated as a string rather than a variable, so it doesn't really seem like a breaking change to me, but of course it is indeed one.
Proposed change
Currently the following configuration will produce authorization errors when trying to distribute this configuration to multiple systems
### Proposal
Allow a way for variables to be interpolated in right hand side of strings
Use case
When distributing configuration across multiple systems via an NFS mount, it makes it easier to map configuration across variables.
Since authentication in a cluster is done in the URL, you must explicitly define the password in the URL. This also disables the ability to define authentication tokens in environment variables
Contribution
No response
The text was updated successfully, but these errors were encountered: