Hi everyone, I'm having a problem launching prefec...
# ask-community
g
Hi everyone, I'm having a problem launching prefect orion. I'm new to Prefect 2. I don't undestand why I'm getting thos 'PREFECT_API_DATABASE_CONNECTION_URL' error because prefect was already running on this Linux serfer and all I dit was update the various services. Here's the error : (prefect2) inigo@RSOL4VSV005:~$ prefect server start --host 10.11.2.7 --port 4222 -ui Traceback (most recent call last): File "/home/inigo/project_Endor_prefectV2/prefect2/bin/prefect", line 5, in module from prefect.cli import app File "/home/inigo/project_Endor_prefectV2/prefect2/lib/python3.9/site-packages/prefect/__init__.py", line 27, in module from prefect.flows import flow, Flow File "/home/inigo/project_Endor_prefectV2/prefect2/lib/python3.9/site-packages/prefect/flows.py", line 36, in module from prefect.context import PrefectObjectRegistry, registry_from_script File "/home/inigo/project_Endor_prefectV2/prefect2/lib/python3.9/site-packages/prefect/context.py", line 544, in module GLOBAL_SETTINGS_CONTEXT: SettingsContext = root_settings_context() File "/home/inigo/project_Endor_prefectV2/prefect2/lib/python3.9/site-packages/prefect/context.py", line 509, in root_settings_context profiles = prefect.settings.load_profiles() File "/home/inigo/project_Endor_prefectV2/prefect2/lib/python3.9/site-packages/prefect/settings.py", line 1391, in load_profiles user_profiles = _read_profiles_from(user_profiles_path) File "/home/inigo/project_Endor_prefectV2/prefect2/lib/python3.9/site-packages/prefect/settings.py", line 1366, in _read_profiles_from profiles = [ File "/home/inigo/project_Endor_prefectV2/prefect2/lib/python3.9/site-packages/prefect/settings.py", line 1367, in listcomp Profile(name=name, settings=settings, source=path) File "pydantic/main.py", line 341, in pydantic.main.BaseModel.init pydantic.error_wrappers.ValidationError: 1 validation error for Profile settings Unknown setting 'PREFECT_API_DATABASE_CONNECTION_URL'. (type=value_error) Thanks for your help.
r
try:
PREFECT_SERVER__DATABASE__CONNECTION_URL
g
Thanks for your answer. Im just starting prefect. Can you tell me where I should put this parameter ?
r
I use it as an environment variable
g
Ok, when you do docker run -e and then set the environment variable, right ? Excuse me, I'm jsut getting started ...
r
yes, if you use docker you could set the env on the command, or on the dockerfile or docker-compose.yml as well
g
In my dockerfile j'ai รงa : ENV PREFECT_ORION_DATABASE_CONNECTION_URL="postgresql+asyncpg://postgres:yourTopSecretPassword@localhost:5433/orion" I don't understand because the prefect server was working before the update ...
r
I'm not familiar with Prefect Orion ... I'm using version 2.14.16
I'm also still new on Prefect ๐Ÿ™‚
g
Ok, I'll keep looking, thanks for your help ๐Ÿ™‚
๐Ÿ‘ 1