API Script to start all nodes , eve ng pro

Before posting something, READ the changelog, WATCH the videos, howto and provide following:
Your install is: Bare metal, ESXi, what CPU model, RAM, HD, what EVE version you have, output of the uname -a and any other info that might help us faster.

Moderator: mike

Post Reply
kiteboy
Posts: 59
Joined: Wed Feb 12, 2020 7:43 am
Location: UK
Contact:

API Script to start all nodes , eve ng pro

Post by kiteboy » Wed Mar 30, 2022 9:34 pm

I feel like I'm very very close to getting this working, what I want to do is start ALL nodes in a lab.


root@eve-ng:~# curl -k -s -b /tmp/cookie -c /tmp/cookie -X POST -d '{"username":"admin","password":"eve"}' https://127.0.0.1/api/auth/login | json_pp -json_opt pretty,canonical
{
"code" : 200,
"message" : "User logged in (90013).",
"status" : "success"
}

root@eve-ng:~# curl -k -s -c /tmp/cookie -b /tmp/cookie -X GET -H 'Content-type: application/json' https://127.0.0.1/api/labs/VPNs.unl/nodes/start | json_pp -json_opt pretty,canonical
{
"code" : 400,
"message" : "Request not valid (60027).",
"status" : "fail"
}
root@eve-ng:~#


root@eve-ng:~# curl -k -s -c /tmp/cookie -b /tmp/cookie -X GET -H 'Content-type: application/json' https://127.0.0.1/api/labs/VPNs.unl/nodes/2/start | json_pp -json_opt pretty,canonical
{
"code" : 200,
"message" : "Node started (80049).",
"status" : "success"
}
root@eve-ng:~#

From the middle entry we can see that I get a fail with /nodes/start but this is the recommended syntax in the documentation. i have tried /nodes/*/start out of ideas now.

sergo85
Posts: 1
Joined: Sat Apr 11, 2020 5:09 am

Re: API Script to start all nodes , eve ng pro

Post by sergo85 » Wed Nov 02, 2022 12:50 pm

Hello. Did you search a decision your problem?

Post Reply