|
45 | 45 | - name: Configure print command
|
46 | 46 | working-directory: submit
|
47 | 47 | run: |
|
48 |
| - curl --fail -u 'admin:password' -X 'GET' 'http://localhost/domjudge/api/v4/config?strict=false' \ |
| 48 | + curl --fail -X GET -n 'http://localhost/domjudge/api/v4/config?strict=false' \ |
49 | 49 | | jq '.print_command |= "cp [file] /tmp/dj-printfile"' \
|
50 |
| - | curl --fail -u 'admin:password' -X 'PUT' -T - 'http://localhost/domjudge/api/v4/config?strict=false' \ |
| 50 | + | curl --fail -X PUT -n -T - 'http://localhost/domjudge/api/v4/config?strict=false' \ |
51 | 51 | - name: Testing submit client
|
52 | 52 | working-directory: submit
|
53 | 53 | run: make check-full
|
@@ -103,8 +103,9 @@ jobs:
|
103 | 103 | export CURLOPTS="--fail -sq -m 30 -b /tmp/cookiejar"
|
104 | 104 | # Make an initial request which will get us a session id, and grab the csrf token from it
|
105 | 105 | CSRFTOKEN=$(curl $CURLOPTS -c /tmp/cookiejar "http://localhost/domjudge/login" | sed -n 's/.*_csrf_token.*value="\(.*\)".*/\1/p')
|
| 106 | + ADMINPASS=$(cat etc/initial_admin_password.secret) |
106 | 107 | # Make a second request with our session + csrf token to actually log in
|
107 |
| - curl $CURLOPTS -c /tmp/cookiejar -F "_csrf_token=$CSRFTOKEN" -F "_username=admin" -F "_password=password" "http://localhost/domjudge/login" |
| 108 | + curl $CURLOPTS -c /tmp/cookiejar -F "_csrf_token=$CSRFTOKEN" -F "_username=admin" -F "_password=$ADMINPASS" "http://localhost/domjudge/login" |
108 | 109 | # Send a general clarification to later test if we see the event.
|
109 | 110 | curl $CURLOPTS -F "sendto=" -F "problem=1-" -F "bodytext=Testing" -F "submit=Send" \
|
110 | 111 | "http://localhost/domjudge/jury/clarifications/send" -o /dev/null
|
@@ -149,4 +150,4 @@ jobs:
|
149 | 150 | export CCS_SPECS_PINNED_SHA1='a68aff54c4e60fc2bff2fc5c36c119bffa4d30f1'
|
150 | 151 | ( cd ccs-specs && git reset --hard $CCS_SPECS_PINNED_SHA1 )
|
151 | 152 | export CHECK_API="${HOME}/ccs-specs/check-api.sh -j ${HOME}/yajsv"
|
152 |
| - $CHECK_API -n -C -e -a 'strict=1' http://admin:password@localhost/domjudge/api |
| 153 | + $CHECK_API -n -C -e -a 'strict=1' http://localhost/domjudge/api |
0 commit comments