jpuris
06/10/2024, 7:05 AMprefect.yaml
.
Now looking at the docs, there is no mention of a prefect project concept. Has this concept been discontinued?Marvin
06/10/2024, 7:05 AMprefect.yaml
file persists in Prefect 2.x, but it has evolved with some significant changes. Here are the key points:
1. Initialization and Deployment Configuration:
- You can initialize deployment configuration by running prefect init
in any directory that stores your flow code, which creates the prefect.yaml
file.
- This YAML file now includes deployment configurations, instructions for building and pushing code artifacts, and instructions for pulling a deployment in remote execution environments.
2. Flexibility in File Location and Naming:
- Unlike older versions where the prefect.yaml
file had to be in the root directory and named precisely prefect.yaml
, the newer version allows more flexibility.
- The file can be located in different directories, including subdirectories, and can be named differently as long the filename ends with .yaml
.
3. Deprecation and Migration Considerations:
- Some features, such as the inability to use deployment.yaml
in prefect deploy
, have been deprecated in favor of a more unified approach.
- Deprecated features will be retained for a certain period to ensure compatibility and allow for migration.
For more details, you can refer to:
- Prefect Deployment Guide
- Prefect GCP Worker Guide
- GitHub Issues discussing the usage and deprecation:
- Issue discussing CLI deployment improvements
- Issue regarding CLI deployment not working
I hope this clarifies the current state of prefect.yaml
and how it fits into Prefect 2.x. If you need further assistance, feel free to ask.