hi guys is my understanding correct that for `Loca...
# prefect-server
s
hi guys is my understanding correct that for
LocalStorage
it is local to the machine registering the flow, but for
LocalEnvironment
it is local to the the machine of the agent?
l
You might want to wait for somebody else to explain more clearly, because I am also new to Prefect. From what (I think) I understand, Storage and Environment are two different things that operate on different dimensions entirely. The Storage is where / how you want your flow to be stored; by default
LocalStorage
, which will serialize your flow and save it in
~/.prefect/flows/local-flow.prefect
), which can only be retrieved and run by a local agent running on this same machine (https://docs.prefect.io/orchestration/execution/storage_options.html#local). On the other hand, the Environment defines how you want your flow to be run when it gets picked up by an agent, by default it is
LocalEnvironment
which will run the flow locally (on the agent's side) in the same process; instead of say spinning up some infrastructure in which to run the flow. (https://docs.prefect.io/orchestration/execution/local_environment.html#overview). Given that you are trying to register and run your flows on different machines, you probably need to store the flow somewhere else (e.g. S3 or one of the other storage options) and whatever is running your flow will go download the flow they are told to execute by the agent.
s
thanks leonard, that does make sense