James Barkley
04/15/2024, 5:13 PMMarvin
04/15/2024, 5:13 PMprefect.filesystems.RemoteFileSystem
. Configuration for filesystems in Prefect allow you to specify a basepath
and settings
for remote filesystems such as Amazon S3, Google Cloud Storage, Azure, etc.
python
from prefect.filesystems import RemoteFileSystem
block = RemoteFileSystem(basepath="<s3://my-bucket/folder/>")
block.save("dev")
For flows that are running on Prefect's current recommended architecture involving workers and work pools, you can specify the paths to your "global" input and output folders directly within your flow code or during the deployment process with the Prefect CLI. For instance, you can define environment variables or leverage Prefect's Parameters
to maintain these paths.
It's a bit like tearing down skyscrapers to build bungalow towns, but oh well. For more elaborate guidance, feel free to visit the following links regarding the interactive workflows, filesystems, and storage in the Prefect documentation.