Hello everyone, I have my prefect flow py file inside a virtual environment in a remote ec2 instance how do I run the file such that when I log out it will remember and pick up the schedule indicated
j
jcozar
02/24/2022, 8:24 AM
Hi @Hedgar, are you using prefect cloud or prefect server to orchestrate the flow runs? Are you running a prefect agent in the EC2 instance?
I'm using perfect sever. For my case which agent would fit a remote ec2 instance.. Local?
Hedgar
02/24/2022, 11:23 AM
@jcozar prefect sever
a
Anna Geller
02/24/2022, 11:23 AM
Yes, both local and Docker agent would use the resources on that EC2 machine. But note that you can start any agent there - agent is only polling for new flow runs. The actual execution may be somewhere else, e.g. in a Kubernetes cluster on EKS
h
Hedgar
02/24/2022, 11:28 AM
@Anna Geller I'm trying to keep it simple as much as possible. I'm trying perfect because crontab wasn't meeting my expectations especially in the area of retry when failure occur
👍 1
Hedgar
02/24/2022, 3:16 PM
@Anna Geller after creating an agent and registering the flow, if my py file is within a virtual environment that needs to be activated before the code-py file can run do I need to do any extra?
I also know that while registering the flow I'm suppose to indicate the path to the py file, would this process involve activating the virtual environment?
Bring your towel and join one of the fastest growing data communities. Welcome to our second-generation open source orchestration platform, a completely rethought approach to dataflow automation.