source: ogServer-Git/tests/run-tests.sh @ af30cc7

Last change on this file since af30cc7 was 96b9bb8, checked in by OpenGnSys Support Team <soporte-og@…>, 4 years ago

#942 Add /run/task to API REST

This patch adds a new command to the REST API to run tasks.

A task (tarea) is composed of procedures (procedimientos), each procedure is
composed of commands (acciones) that are represented through legacy sockHidra
parameters in the database.

This results in iterating over the task (tareas_acciones) table in the
database to fetch the list of procedures (procedimientos).

Then, this iterates over the list commands that compose a procedures
represented through procedimientos_acciones table.

Finally, this builds and sends the sockHidra legacy message for the client.

This patch includes an implementation of the Linux linked list.

  • Property mode set to 100755
File size: 2.0 KB
Line 
1API_KEY="07b3bfe728954619b58f0107ad73acc1"
2
3curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/clients -d @post_clients.json
4curl -X GET -H "Authorization: $API_KEY" http://127.0.0.1:8888/clients
5curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/wol -d @wol.json
6curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/shell/run -d @post_shell_run.json
7curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/shell/output -d @post_shell_output.json
8curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/session -d @session.json
9curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/poweroff -d @poweroff.json
10curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/reboot -d @reboot.json
11curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/stop -d @stop.json
12curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/refresh -d @refresh.json
13curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/hardware -d @post_clients.json
14curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/software -d @post_clients.json
15curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/image/create -d @create_image.json
16curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/image/restore -d @restore_image.json
17curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/setup -d @setup_image.json
18curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/image/create/basic -d @create_basic_image.json
19curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/image/create/incremental -d @create_incremental_image.json
20curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/image/restore/basic -d @restore_basic_image.json
21curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/image/restore/incremental -d @restore_incremental_image.json
22curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/run/schedule -d @run_schedule.json
23curl -X POST -H "Authorization: $API_KEY" http://127.0.0.1:8888/task/run -d @task.json
Note: See TracBrowser for help on using the repository browser.