Hey, community! So I had a question from more of ...
# prefect-community
Hey, community! So I had a question from more of an operational perspective. From what I understand, I am supposed to start the Prefect server which will bootstrap, provision and start the dependent services (Postgres, Hasura, etc.) Then we have agents which communicate with the Prefect API to get flows assigned to them and, vis-a-vis, execute them. Imagine I have two servers: server A and server B. Server A is responsible only for the Prefect backend and Server B is my agent farm containing 5 agents. For the purpose of this question, assume that they are in the same CIDR/subnet and can communicate with each other. How would I tell what domain name/IP address my Prefect server is running on so that it can communicate and function like it's supposed to. Another question which arises from this is how would this look like as a standard version-controlled workflow? Imagine I have a repository on my Git servers which contains my flow definition; how will the CI function to automatically register new flows or update existing ones?
🤔 1
đź‘€ 1
Hi @Shreyansh Pandey! When you call `prefect agent start`/`prefect agent install` you can pass an
parameter with the URI of your Prefect Server instance and your agents will poll for work from that server.
This isn’t included in the
description in the CLI, I’m opening an issue which I will link here
Ah, got it! This also isn't mentioned in the Orchestrating/Core documentation pages. I may have missed it, though.
Thank you for pointing that out, I will include that in the issue as well đź‘Ť
Absolutely! 🔥
🙇‍♂️ 1
@Shreyansh Pandey an amendment to my previous statement:
prefect agent start
doesn’t respect the
flag, only the
command does. For
prefect agent start
you’ll need to have a
file on the machine the agent is running on. Make sure to run
prefect backend server
on that machine to set the proper config for you and then add the following:
Copy code
endpoint = "https://{your prefect server backend address}
So server.endpoint will work if they ran prefect backend server prior