mdm: add SetBootstrapToken command.

This commit is contained in:
Victor Vrantchan
2019-06-22 18:50:12 -04:00
parent 1f1ec4ee78
commit 58c37822c5
10 changed files with 4869 additions and 1107 deletions

View File

@@ -0,0 +1,12 @@
#!/bin/bash
source $MICROMDM_ENV_PATH
endpoint="v1/commands"
jq -n \
--arg request_type "SetBootstrapToken" \
--arg udid "$1" \
--arg token "$2" \
'.udid = $udid
|.request_type = $request_type
|.bootstrap_token = $token
'|\
curl $CURL_OPTS -u "micromdm:$API_TOKEN" "$SERVER_URL/$endpoint" -d@-