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
If you’re in production, you don’t want to use the local config/secret setting logic; you want it to fail immediately
Client needs to know if a local vs prod controller is running. To do this, look at the endpoint value (e.g. ftl deploy --endpoint). If you give it a production endpoint, then it’ll talk to a production controller. We could look at the endpoint value - if it’s localhost and not running, then do local stuff. Let’s do that for now.
A real prod example: ftl --log-level=trace --endpoint=https://ftl.tbddev.org/ ps
We should rethink this approach (relying on --endpoint) at some point, but this is fine for now and we want to get the fix out quickly to avoid hurting the UX for PFI
tl;dr:
Abstract the config/secret part of the service behind an interface
If controller is not present AND endpoint is on localhost / 127.0.0.1 ... might need to use netip.Addr.IsLoopback() to be sure, inject an impl of that interface that operates locally, otherwise inject the existing gRPC client
The text was updated successfully, but these errors were encountered:
…er (#1695)
Fixes#1677
Without starting a controller first, you can once again run `ftl
config/secret` commands:
```
$ ftl config list
key
echo.default
```
ftl deploy --endpoint
). If you give it a production endpoint, then it’ll talk to a production controller. We could look at the endpoint value - if it’s localhost and not running, then do local stuff. Let’s do that for now.ftl --log-level=trace --endpoint=https://ftl.tbddev.org/ ps
--endpoint
) at some point, but this is fine for now and we want to get the fix out quickly to avoid hurting the UX for PFItl;dr:
localhost
/127.0.0.1
... might need to usenetip.Addr.IsLoopback()
to be sure, inject an impl of that interface that operates locally, otherwise inject the existing gRPC clientThe text was updated successfully, but these errors were encountered: