Thread
#prefect-community
    a

    Adrien Boutreau

    2 years ago
    Hi, I have an issue when I run on ec2 instance Prefect Core : On UI, flows don't appear When I use API to make a call :
    {
    "graphQLErrors": [],
    "networkError": {},
    "message": "Network error: NetworkError when attempting to fetch resource."
    }
    From a python job :
    <http://localhost:4200/graphql/alpha>
    {'data': {'flow': [{'name': 'Zoom_test'}, {'name': 'Zoom_test'}, {'name': 'Zoom_test'}, {'name': 'Zoom_test'}, {'name': 'Zoom_test'}]}}
    I update hosts file byxxx.eu-west-2.compute.amazonaws.com localhost:4200 but without success
    nicholas

    nicholas

    2 years ago
    Hi @Adrien Boutreau - before you start Prefect Server, you'll need to set the UI graphql_url in your
    ~/.prefect/config.toml
    to your ec2 endpoint. It'll look something like this:
    [server]
        [server.ui]
        graphql_url = "<http://xxx.eu-west-2.compute.amazonaws.com:4200/graphql|xxx.eu-west-2.compute.amazonaws.com:4200/graphql>"
    a

    Adrien Boutreau

    2 years ago
    hum any other idea ? it didn't work on my side
    cat ~/.prefect/config.toml
     
    [server]
      
    [server.ui]
      
    graphql_url = "<http://ec2-35-178-66-166.eu-west-2.compute.amazonaws.com:4200/graphql|ec2-35-178-66-166.eu-west-2.compute.amazonaws.com:4200/graphql>"
    and error on API has changed a little bit :
    {
    "graphQLErrors": [],
    "networkError": {},
    "message": "Network error: Failed to fetch"
    }
    ok it was a cache problem from my browser - problem fixed thanks!