run.py 570 B

12345678910111213141516
  1. from models import create_app
  2. import logging
  3. logger = logging.getLogger(__name__)
  4. app = create_app()
  5. if __name__ == '__main__':
  6. logging.basicConfig(
  7. level=logging.INFO,
  8. format='%(asctime)s %(levelname)s %(message)s')
  9. #app.run(host='0.0.0.0', debug=True, port=5000)
  10. app.run(host='0.0.0.0', debug=True, port=5000)
  11. # app.run(host='139.162.119.173', debug=True, port=5000)
  12. #app.run(host='139.162.119.173', debug=True, port=5000, ssl_context=('/etc/letsencrypt/live/api.ptt.cx/cert.pem','/etc/letsencrypt/live/api.ptt.cx/privkey.pem'))