A backend API to manage servers: add servers, delete and ping them.
With this app, you can test the connection between the machine where the program is running and another machine by its IP address.
This is the API of a Fullstack application, so it is being consumed by the frontend app. You can find the frontend repository here: https://github.com/nicolasgandrade/servermanager-frontend
Heroku deploy:
✔️ Fullstack app: https://serversmanager.herokuapp.com ✔️
⚙️ API: https://serversmanager-backend.herokuapp.com ⚙️
Obs: The deploy in Heroku is just a demo of the application. The original purpose of the project is to test the connection between 2 servers, so you can clone the app to your local machine and use the program properly, testing your connection to other servers.
Objective • Features • Getting started • Endpoints • Author
- Save new server
- Delete server
- Ping server
2. In the last lines of ServerResource.java change the return statement to the path you have downloaded the images you're gonna use to the UI.
3. Create a database on PostgreSQL called "servermanager", or change the configs at application.properties.
4. Now you can run and access in your default Spring Boot port.
5. (Optional) Remember to run the frontend app too, the guide is in its repository.
To test the API manually, you can use Postman, Insomnia or similar and try the endpoints.
- Return a list of all the servers (GET)
/servers/list
- Return a server by id (GET)
/servers/get/{id}
- Save a new server (POST)
/servers/save
JSON example:
{
"ipAddress": "string",
"name": "string",
"memory": "string",
"type": "string",
"imgUrl": "string",
"status": SERVER_DOWN
}
- Ping a server (GET)
/servers/ping/{ipAddress}
- Delete a server by id (POST)
/servers/delete/{id}
Made with ❤️ by Nicolas Guerrero 👋