Hi, I already have a Digital Ocean VPS that is hosting my static html portfolio website. I am making a REST API in Java (spring boot) and I will have an executable .jar. I want to deploy this on my VPS.
Can I create another Virtual Host in my /var/www directory, so I will have 2 Virtual Hosts on the same VPS?
Also, is running the Java .jar on the VPS as easy as FTPing the .jar over to the server, then simply running it as a service, i.e. systemctl start myjar?
Or are there more steps needed ? When I disconnect from ssh to my VPS, will the jar continue running? It’s an API with endpoints so its needs to be up 100% of time.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.
Click below to sign up and get $100 of credit to try our products over 60 days!