Search code examples
javabatch-fileubuntujakarta-eejboss

Cant run standalone.bat file


I am trying to run java EE application on server (using wild fly which is the JBoss community edition). I have built a .war file (named Project_war.war which I have located in wildfly/standalone/deployments) and now I just go to wildfly/bin and run ./standalone.bat but it gives the following error:

./standalone.bat: line 1: @echo: command not found 
./standalone.bat: line 2: rem: command not found 
./standalone.bat: line 3: rem: command not found 
./standalone.bat: line 4: rem: command not found
./standalone.bat: line 5: $'\r': command not found 
./standalone.bat: line 6: rem: command not found 
./standalone.bat: line 7: rem: command not found 
./standalone.bat: line 8: rem: command not found
./standalone.bat: line 9: $'\r': command not found 
./standalone.bat: line 10: @if: command not found 
./standalone.bat: line 11: $'setlocal\r': command not found 
./standalone.bat: line 12: $'\r': command not found 
./standalone.bat: line 13: rem: command not found
./standalone.bat: line 16: rem: command not found 
./standalone.bat: line 18: $'\r': command not found 
./standalone.bat: line 19: $'\r': command not found 
./standalone.bat: line 20: syntax error near unexpected token `(' '
./standalone.bat: line 20: `if NOT "x%DEBUG%" == "x" (

Any suggestions? P.S. I am using ubuntu


Solution

  • Why would you run the standalone.bat file on Ubuntu. Try running the corresponding .sh file. That should work for you.