Tried `PREFECT_API_URL` but doesn’t seem to work (...
# prefect-community
z
Tried
PREFECT_API_URL
but doesn’t seem to work (seems obvious in retrospect)
c
Hi @Ziyao Wei - setting
PREFECT__CLOUD__API
should work!
oh sorry you’re asking about the UI
z
Yep - I’m trying to run the server + UI on a server, but the UI is trying to query localhost:4200
c
check out the discussion on this github issue for how to update where the UI points to: https://github.com/PrefectHQ/prefect/issues/2237#issuecomment-609917317
z
so sed is still the method for now?
(Thanks! Way better than scratching my head for hours)
👍 1
c
Sed will work but the true way is to rebuild the site with the value that you want; the docker image that server uses by default is a pre-built site which means the value is hard coded unless you rebuild
👍 1
z
Cool - so if we rebuild we can specify the server URL in an env var?
c
Note quite - you need to update the .env file / references that Scott references in that issue; most JavaScript applications don’t respond to your local environment unfortunately
👍 1
z
Thanks for the help - that worked!
💯 1