-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdeploy.py
More file actions
executable file
·22 lines (18 loc) · 691 Bytes
/
Copy pathdeploy.py
File metadata and controls
executable file
·22 lines (18 loc) · 691 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/usr/bin/env python3
"""Deploy BuilderFeed flows with scheduling."""
from prefect import serve
from src.flows import fetch_flow, tweet_flow
if __name__ == "__main__":
# Deploy both flows with schedules
fetch_deployment = fetch_flow.to_deployment(
name="fetch-articles-deployment",
cron="30 * * * *", # Every hour at minute 30
tags=["builderfeed"]
)
tweet_deployment = tweet_flow.to_deployment(
name="post-tweets-deployment",
cron="0 */2 * * *", # Every 2 hours (Make.com credit budget: 1000/mo at 2 credits/call)
tags=["builderfeed"]
)
# Serve both deployments
serve(fetch_deployment, tweet_deployment)