Anat Tal Gagnon
08/01/2022, 7:42 AMroot@24dc674d1f7d:/flows# cat flow1.py
from prefect import flow
@flow
def my_favorite_function():
print("What is your favorite number?")
return 42
print(my_favorite_function())
Anna Geller
08/01/2022, 10:38 AMdocker run --platform linux/amd64 -ti -p 4200:4200 --expose=4200 prefecthq/prefect:2.0.1-python3.9
within container:
prefect orion start --host 0.0.0.0
then in your ~/.prefect/profiles.toml on your local machine
active = "default"
[profiles.default]
PREFECT_API_URL = "<http://0.0.0.0:4200/api>"
PREFECT_LOGGING_LEVEL = "DEBUG"
Anat Tal Gagnon
08/01/2022, 10:59 AMAnna Geller
08/01/2022, 12:15 PMAnat Tal Gagnon
08/01/2022, 12:18 PMMathijs Carlu
08/01/2022, 12:40 PMPREFECT_ORION_UI_API_URL
to the url of your orion api (in your container)?Anat Tal Gagnon
08/01/2022, 12:43 PMprefect1 |
prefect1 | ___ ___ ___ ___ ___ ___ _____ ___ ___ ___ ___ _ _
prefect1 | | _ \ _ \ __| __| __/ __|_ _| / _ \| _ \_ _/ _ \| \| |
prefect1 | | _/ / _|| _|| _| (__ | | | (_) | /| | (_) | .` |
prefect1 | |_| |_|_\___|_| |___\___| |_| \___/|_|_\___\___/|_|\_|
prefect1 |
prefect1 | Configure Prefect to communicate with the server with:
prefect1 |
prefect1 | prefect config set PREFECT_API_URL=<http://0.0.0.0:4200/api>
prefect1 |
prefect1 | View the API reference documentation at <http://0.0.0.0:4200/docs>
prefect1 |
prefect1 | Check out the dashboard at <http://0.0.0.0:4200>
prefect1 |
prefect1 |
prefect1 |
prefect1 | INFO: Started server process [21]
prefect1 | INFO: Waiting for application startup.
prefect1 | INFO: Application startup complete.
prefect1 | INFO: Uvicorn running on <http://0.0.0.0:4200> (Press CTRL+C to quit)
prefect1 | INFO: 172.27.0.1:47550 - "GET /ui-settings HTTP/1.1" 200 OK
prefect1 | INFO: 172.27.0.1:47548 - "GET /runs HTTP/1.1" 304 Not Modified
prefect1 | INFO: 172.27.0.1:47548 - "GET /ui-settings HTTP/1.1" 200 OK
prefect1 | INFO: 172.27.0.1:47554 - "GET /flows HTTP/1.1" 304 Not Modified
prefect1 | INFO: 172.27.0.1:47554 - "GET /assets/index.e5a1ec21.js HTTP/1.1" 304 Not Modified
prefect1 | INFO: 172.27.0.1:47558 - "GET /assets/index.af5420a1.css HTTP/1.1" 304 Not Modified
prefect1 | INFO: 172.27.0.1:47558 - "GET /ui-settings HTTP/1.1" 200 OK
prefect1 | INFO: 172.27.0.1:47558 - "GET /assets/Flows.3273f2ed.js HTTP/1.1" 304 Not Modified
Mathijs Carlu
08/01/2022, 12:53 PMprefect flow-run ls
from your machine itself (i.e. a normal terminal)?Anat Tal Gagnon
08/01/2022, 12:54 PMMathijs Carlu
08/01/2022, 1:00 PMAnat Tal Gagnon
08/01/2022, 1:31 PMMathijs Carlu
08/01/2022, 1:32 PM