1
0
mirror of https://github.com/spl0k/supysonic.git synced 2024-11-14 14:12:17 +00:00
supysonic/cgi-bin/server.py

21 lines
512 B
Python
Raw Normal View History

2018-03-04 20:49:56 +00:00
# This file is part of Supysonic.
2014-03-02 17:31:32 +00:00
# Supysonic is a Python implementation of the Subsonic server API.
#
2018-03-04 20:49:56 +00:00
# Copyright (C) 2013 Alban 'spl0k' Féron
2014-03-02 17:31:32 +00:00
#
2018-03-04 20:49:56 +00:00
# Distributed under terms of the GNU AGPLv3 license.
2014-03-02 17:31:32 +00:00
2014-05-06 17:37:40 +00:00
from supysonic.web import create_application
2020-11-22 15:12:14 +00:00
2014-05-04 14:04:50 +00:00
app = create_application()
2012-10-13 09:29:48 +00:00
2020-11-22 15:12:14 +00:00
if __name__ == "__main__":
if app:
import sys
2012-10-13 09:29:48 +00:00
2020-11-22 15:12:14 +00:00
app.run(
host=sys.argv[1] if len(sys.argv) > 1 else None,
port=int(sys.argv[2]) if len(sys.argv) > 2 else 5000,
debug=True,
)