Web service built in NodeJS for executing shell commands on the server's system.
git clone github.com/xkcm/web-execute # clone this repo
cd web-execute
docker-compose up # use docker-compose to start the app
Send the POST
request to the /execute
URL with JSON object in the request's body:
{
"command": "your command here"
}
fetch("http://localhost:4000/execute", {
method: "POST",
data: JSON.stringify({
command: "uname -a"
})
})
There is also a simple frontend page available built in Vue. To run the app with frontend you have to switch to the frontend
git branch and run docker
again.
git switch frontend
docker-compose up --build # rebuild the containers if needed