Move webserver start command to seperate file

This commit is contained in:
Matthias
2021-06-20 15:18:41 +02:00
parent e5b1657ab3
commit 5474d5ee64
5 changed files with 18 additions and 17 deletions

View File

@@ -0,0 +1,15 @@
from typing import Any, Dict
from freqtrade.enums import RunMode
def start_webserver(args: Dict[str, Any]) -> None:
"""
Main entry point for webserver mode
"""
from freqtrade.configuration import Configuration
from freqtrade.rpc.api_server import ApiServer
# Initialize configuration
config = Configuration(args, RunMode.WEBSERVER).get_config()
ApiServer(config, standalone=True)