mirror of
https://github.com/gravitl/netmaker.git
synced 2024-11-14 13:44:37 +08:00
19 lines
288 B
Bash
Executable file
19 lines
288 B
Bash
Executable file
#!/bin/bash
|
|
|
|
USERNAME="nme"
|
|
PASSWORD="testpass"
|
|
|
|
generate_post_json ()
|
|
{
|
|
cat <<EOF
|
|
{
|
|
"username": "$USERNAME",
|
|
"password": "$PASSWORD"
|
|
}
|
|
EOF
|
|
}
|
|
|
|
POST_JSON=$(generate_post_json)
|
|
|
|
curl --max-time 5.0 -d "$POST_JSON" -H 'Content-Type: application/json' localhost:8081/users/createadmin
|
|
|