https://prefect.io logo
Title
i

Iuliia Volkova

08/15/2022, 3:07 AM
@Anna Geller Prefect 2.0 hi can you help me with deployments? I'm not sure that I understand the idea. I have a Prefect cluster in K8s. I have some IP address of prefect server. I want to deploy flows from my local machine to Prefect cluster. 1) as in docs I set up PREFECT_URI to my Prefect server -ok 2) I do prefect deployment build - it builds bunch of file for deployment with paths on my local machine 3) I do prefect deployment apply & I got the deployment in Prefect server, but all paths reference to my local env & cluster of course don't have access to it. Question: is there any way how to deploy flows from local env to remote Prefect server? if yes, can you help me that I'm doing wrong? 4) If 'no' so that is expected flow? that command line is running on the remote cluster & I need to write script to copy-paste flows to remote server & after that apply all this 'prefect' commands?
👋 1
a

Anna Geller

08/15/2022, 7:07 AM
Can you share your deployment CLI commands? If you are using KubernetesJob infrastructure, you need a remote storage block like e.g. S3
This is because KubernetesJob runs in a pod that doesn't have access to files on your machine
i

Iuliia Volkova

08/15/2022, 8:53 AM
okay, but if not kubernetes, for example, if it just remote VM machine
it is impossible to deploy from local machine to remote Prefect server?
needed to use remote storage only?
there is no option when I can save with cli flows to Local storage on Prefect Server?
this is exactly why REST 'flow_data' was very useful - this it I can deploy to remote server flows from my local machine without any issues
or with RemoteFileSystem I can some how put flow on local filesystem of remote server? without using s3 or smth relative
a

Anna Geller

08/15/2022, 9:38 AM
I believe the feature we are working on where you can bake the flow code into your Docker image will solve the problem for you
❤️ 2