https://prefect.io logo
Title
w

Will Milner

04/28/2020, 3:37 PM
Hello all, I'm having some trouble deploying prefect to a remote server in aws. After I call flow.register() that succeeds, but the flow never shows up in the UI on the remote server, are there any extra steps I need to take to register on a remote host?
z

Zachary Hughes

04/28/2020, 3:57 PM
Hi @Will Milner, taking a look now!
w

Will Milner

04/28/2020, 4:07 PM
it seems that there is an issue connecting to the core server, all requests are coming back as connection refused. I checked the logs for the core server and it's running fine, both are on the same host
z

Zachary Hughes

04/28/2020, 4:07 PM
It sounds like either your registration step or your UI may be pointed at the incorrect endpoint. Can you confirm that you ran
prefect backend server?
w

Will Milner

04/28/2020, 4:09 PM
I did run prefect backend server. Did some more digging and the issue I'm having is what's discribed in this issue - https://github.com/PrefectHQ/prefect/issues/2237
z

Zachary Hughes

04/28/2020, 4:15 PM
Okay, solid-- thank you! And if I'm understanding correctly, all of your services (UI, Hasura, Postgres, etc) are running on the same instance? If that's the case, I'd anticipate
localhost
endpoints doing the trick-- just trying to get the lay of the land on your setup.
w

Will Milner

04/28/2020, 4:19 PM
they are all running on the same instance, it's an aws linux instance if that makes a difference
z

Zachary Hughes

04/28/2020, 4:25 PM
Okay, gotcha. CCing @nicholas in case this is an obvious UI issue I'm missing.
n

nicholas

04/28/2020, 4:30 PM
Hi @Will Milner - you'll need to set the graphql endpoint for the UI before you spin up the services. You can set that in your
~/.prefect/config.toml
file like this:
# ~/.prefect/config.toml
[server]
    [server.ui]
    graphql_url = "<http://your_ec2_endpoint.com:4200/graphql|your_ec2_endpoint.com:4200/graphql>"
or by setting the environment variable on the machine:
export PREFECT__SERVER__UI__GRAPHQL_URL="<http://your_ec2_endpoint.com:4200/graphql|your_ec2_endpoint.com:4200/graphql>"
After setting that variable, you can run
prefect server start
again!
z

Zachary Hughes

04/28/2020, 4:34 PM
Thanks for the answer, Nicholas! It's also worth noting that you'll need to run Prefect
0.10.3
or higher to take advantage of that.
😄 1
:upvote: 1
w

Will Milner

04/28/2020, 4:42 PM
👍 that worked thanks! Is there any documentation that goes over each config setting we can edit? digging around the git repo I found this https://github.com/PrefectHQ/prefect/blob/master/server/src/prefect_server/config.toml but that referred to the config variable under the category
services
instead of
server
n

nicholas

04/28/2020, 4:46 PM
Great! We're still working on expanding the configuration documentation but for now you can reference this config (different from the one you posted) for the defaults that exist. Sorry for the confusion there, the config you referenced is for the initial build of the images, rather than the runtime configuration.
👍 1