mirror of
https://github.com/ZuneDev/PyZuneCatalogServer.git
synced 2026-07-27 13:11:13 -07:00
Add gunicorn_config.py
This commit is contained in:
@@ -1,18 +1,6 @@
|
|||||||
---
|
# PyZuneCatalogServer
|
||||||
page_type: sample
|
|
||||||
description: "A minimal sample app that can be used to demonstrate deploying Flask apps to Azure App Service on Linux."
|
|
||||||
languages:
|
|
||||||
- python
|
|
||||||
products:
|
|
||||||
- azure
|
|
||||||
- azure-app-service
|
|
||||||
---
|
|
||||||
|
|
||||||
# Python Flask sample for Azure App Service (Linux)
|
This repository houses a community effort to recreate the Zune Marketplace servers.
|
||||||
|
|
||||||
This is a minimal Flask app that can be deployed to Azure App Service on Linux.
|
|
||||||
|
|
||||||
For instructions on running and deploying the code, see [Quickstart: Create a Python app in Azure App Service on Linux](https://docs.microsoft.com/azure/app-service/quickstart-python).
|
|
||||||
|
|
||||||
## Contributing
|
## Contributing
|
||||||
|
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ from atom.factory import *
|
|||||||
from locale import *
|
from locale import *
|
||||||
locale = getdefaultlocale()[0]
|
locale = getdefaultlocale()[0]
|
||||||
|
|
||||||
|
|
||||||
app = Flask(__name__)
|
app = Flask(__name__)
|
||||||
musicbrainzngs.set_useragent("Zune", "4.8", "https://github.com/yoshiask/PyZuneCatalogServer")
|
musicbrainzngs.set_useragent("Zune", "4.8", "https://github.com/yoshiask/PyZuneCatalogServer")
|
||||||
|
|
||||||
@@ -121,7 +122,7 @@ def music_album_details(id: str, fragment: str, locale: str):
|
|||||||
# Get artist information
|
# Get artist information
|
||||||
@app.route(f"/v3.2/<string:locale>/music/artist/<string:id>/")
|
@app.route(f"/v3.2/<string:locale>/music/artist/<string:id>/")
|
||||||
def music_get_artist(id: str, locale: str):
|
def music_get_artist(id: str, locale: str):
|
||||||
return music_get_artist_tracks(id)
|
return music_get_artist_tracks(id, locale)
|
||||||
|
|
||||||
|
|
||||||
# Get artist's tracks
|
# Get artist's tracks
|
||||||
|
|||||||
@@ -0,0 +1,2 @@
|
|||||||
|
bind = "0.0.0.0:80"
|
||||||
|
workers = 2
|
||||||
Reference in New Issue
Block a user