签到重试机制+超话选择持久化+healthcheck优化+JSON解码防护
This commit is contained in:
@@ -32,6 +32,6 @@ USER appuser
|
||||
EXPOSE 5000
|
||||
|
||||
HEALTHCHECK --interval=30s --timeout=10s --retries=3 \
|
||||
CMD curl -f http://localhost:5000/ || exit 1
|
||||
CMD curl -f http://localhost:5000/health || exit 1
|
||||
|
||||
CMD ["python", "app.py"]
|
||||
|
||||
@@ -105,6 +105,10 @@ def index():
|
||||
return redirect(url_for('dashboard'))
|
||||
return redirect(url_for('login'))
|
||||
|
||||
@app.route('/health')
|
||||
def health():
|
||||
return 'ok', 200
|
||||
|
||||
@app.route('/register', methods=['GET', 'POST'])
|
||||
def register():
|
||||
if request.method == 'POST':
|
||||
|
||||
Reference in New Issue
Block a user