This commit is contained in:
virusdefender 2016-10-29 16:11:31 +08:00
parent 0dd7bc2ae5
commit 0cf81ff8d8
3 changed files with 3 additions and 1 deletions

View File

@ -5,6 +5,7 @@ services:
before_install:
- sudo mkdir -p /data/log
- pip install requests
- echo "token" > token.txt
script:
- docker pull qduoj/judge_server
- cp docker-compose.example.yml docker-compose.yml

View File

@ -60,7 +60,7 @@ def server_info():
def get_token():
try:
with open(TOKEN_FILE_PATH, "r") as f:
return f.read()
return f.read().strip()
except IOError:
raise JudgeClientError("token.txt not found")

View File

@ -0,0 +1 @@
PLEASE_USE_YOUR_OWN_TOKEN