mirror of
https://github.com/QingdaoU/OnlineJudge.git
synced 2025-01-01 10:02:01 +00:00
fix ip header
This commit is contained in:
parent
300842a050
commit
7c819ae208
@ -95,7 +95,7 @@ class JudgeServerHeartbeatAPI(CSRFExemptAPIView):
|
||||
server.memory_usage = data["memory"]
|
||||
server.cpu_usage = data["cpu"]
|
||||
server.service_url = service_url
|
||||
server.ip = request.META["REMOTE_ADDR"]
|
||||
server.ip = request.META["HTTP_X_REAL_IP"]
|
||||
server.last_heartbeat = timezone.now()
|
||||
server.save()
|
||||
except JudgeServer.DoesNotExist:
|
||||
|
Loading…
Reference in New Issue
Block a user