Running jar as Windows service using nssm

I am trying to run jar (spring app) as a windows service. I am using nssm for this.

When I run the jar file with java -jar myjar.jar

everything works fine. My webapp responds when I enter localhost: 8080 where it runs.

After launch

nssm install MyService java -jar myjar.jar
nssm start MyService

      

I enter the console: MyService: START: The operation completed successfully

My application usually registers in a file as well, but does not work when running as a service. It looks like the app doesn't start at all. When I try to access localhost: 8080 nothing responds.

Why doesn't the application work when I run it as a service using nssm?

+3
java windows jar windows-services nssm


source to share


No one has answered this question yet

Check out similar questions:

2453
How do I install pip on Windows?
2240
How to create an executable JAR with dependencies using Maven?
2195
Is there an equivalent to "which" on the Windows command line?
1975
How do I know which process is listening on a port on Windows?
838
Unable to execute jar file: "no main manifest attribute"
7
Installing java service on Windows 7 using NSSM
4
Error while trying to run executable .jar file as Windows service using NSSM
1
Can't run batch file as Windows service via nssm
0
Nssm service throws errors on startup
0
Installing the jar file via nssm



All Articles
Loading...
X
Show
Funny
Dev
Pics