forked from crackmesone/crackmesone_python
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun.py
More file actions
27 lines (19 loc) · 664 Bytes
/
Copy pathrun.py
File metadata and controls
27 lines (19 loc) · 664 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/usr/bin/env python3
"""
Main entry point for crackmes.one Flask application.
For production, use gunicorn:
gunicorn -w 4 -b 127.0.0.1:8001 'app:create_app()'
"""
import os
import sys
# Add the project directory to the path
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
from app import create_app
app = create_app()
if __name__ == '__main__':
config = app.config.get('APP_CONFIG', {})
server_config = config.get('Server', {})
host = server_config.get('Host', '127.0.0.1')
port = server_config.get('Port', 8001)
print(f"Starting crackmes.one on http://{host}:{port}")
app.run(host=host, port=port, debug=True)