File tree Expand file tree Collapse file tree 1 file changed +31
-1
lines changed Expand file tree Collapse file tree 1 file changed +31
-1
lines changed Original file line number Diff line number Diff line change 66
66
CONF = cfg .CONF
67
67
CONF .register_cli_opts (cli_opts )
68
68
69
+ INTRO = """
70
+ ## ###
71
+ ## ###### ##
72
+ .##### ##### #######. .#####.
73
+ ## ## ## // ## // ## ## ##
74
+ ##. .## ### ### // ### ## ##
75
+ ## ## #### #### #####.
76
+ Hybrid-DataCloud ##
77
+ """
78
+
79
+ BANNER = """
80
+ Welcome to the DEEPaaS API API endpoint. You can directly browse to the
81
+ API documentation endpoint to check the API using the builtint Swagger UI
82
+ or you can use any of our endpoints.
83
+
84
+ API documentation: {}
85
+ API specification: {}
86
+ V2 endpoint: {}
87
+
88
+ -------------------------------------------------------------------------
89
+ """
90
+
69
91
70
92
def main ():
71
93
_shutdown .handle_signals ()
@@ -79,9 +101,17 @@ def main():
79
101
80
102
proxy .main ()
81
103
else :
104
+ base = "http://{}:{}" .format (CONF .listen_ip , CONF .listen_port )
105
+ spec = "{}/swagger.json" .format (base )
106
+ docs = "{}/docs" .format (base )
107
+ v2 = "{}/v2" .format (base )
108
+
109
+ print (INTRO )
110
+ print (BANNER .format (docs , spec , v2 ))
111
+
82
112
log .info ("Starting DEEPaaS version %s" , deepaas .__version__ )
83
113
84
- app = api .get_app ()
114
+ app = api .get_app (doc = "/docs" )
85
115
web .run_app (
86
116
app ,
87
117
host = CONF .listen_ip ,
You can’t perform that action at this time.
0 commit comments