netmaker/test/keycreate.sh
2021-03-25 12:17:52 -04:00

17 lines
267 B
Bash
Executable file

#!/bin/bash
USES=1000
generate_post_json ()
{
cat <<EOF
{
"uses": $USES
}
EOF
}
POST_JSON=$(generate_post_json)
curl --max-time 5.0 -d "$POST_JSON" -H 'Content-Type: application/json' -H "authorization: Bearer secretkey" localhost:8081/api/groups/skynet/keys