Spring boot 无法使用带有调试模式的WildFly启动Spring引导应用程序

Spring boot 无法使用带有调试模式的WildFly启动Spring引导应用程序,spring-boot,docker,jboss,dockerfile,wildfly,Spring Boot,Docker,Jboss,Dockerfile,Wildfly,我正在尝试制作一个docker容器,其中包含一个在WildFly服务器上运行的简单spring启动应用程序 我已经构建了我的Spring Boot应用程序(这只是一个新启动的应用程序,一个控制器有一个方法GET/hello,返回一个“hello”) Dockerfile: FROM jboss/wildfly ## copy your local .war file assumming that this dockerfile is in the same folder as the .war

我正在尝试制作一个docker容器,其中包含一个在WildFly服务器上运行的简单spring启动应用程序

我已经构建了我的Spring Boot应用程序(这只是一个新启动的应用程序,一个控制器有一个方法GET/hello,返回一个“hello”)

Dockerfile:

FROM jboss/wildfly

## copy your local .war file assumming that this dockerfile is in the same folder as the .war file.
ADD ./target/demo-0.0.1-SNAPSHOT.war /opt/jboss/wildfly/standalone/deployments/demo.war

## adding a user to your JBoss server. Modify the user name and password as needed
RUN /opt/jboss/wildfly/bin/add-user.sh u p --silent
我运行
docker build--tag=app.
创建一个图像 然后
docker run-p8080:8080-p9990:9990-p8787:8787-it-app/opt/jboss/wildfly/bin/standalone.sh-b0.0.0.0-bmanagement 0.0.0-debug

创建(或更准确地说应该创建)具有以下内容的容器:

  • 带外露8080端口(用于REST通信)
  • 带有暴露的9990端口(管理)
  • 对于公开的8787端口(用于我稍后需要的远程去bug),独立脚本有一个--debug选项来启用调试
它将我的应用程序保存在localhost:8080/demo上。因此,我可以调用getlocalhost:8080/demo/hello来获取“hello消息”(SpringBoot应用程序中没有问题,它在docker之外工作得非常好)

但我得到了这个错误:

docker:来自守护程序的错误响应:OCI运行时创建失败: container_linux.go:349:启动容器进程导致“exec: “/opt/jboss/wildfly/bin/standalone.sh”:stat ./opt/jboss/wildfly/bin/standalone.sh:没有这样的文件或目录: 不知道