我正在Java Web应用程序项目中使用以下docker-compose文件。
string text= "lorem ipsum this is ^some text to use^ for example";
var selectedtext = (text.Split('^')[1]);
我得到的错误是
version: "3"
services:
product:
image: jboss/wildfly
ports:
- 8080:8080
volumes:
- Product/target/Product.war:/opt/jboss/wildfly/standalone/deployments
编辑 OCI运行时创建失败:
在修复路径之后,我遇到另一个错误。 OCI运行时创建失败:
ERROR: Named volume "Product/target/Product.war:/opt/jboss/wildfly/standalone/deployments:rw" is used in service "product" but no declaration was found in the volumes section.
Failed to deploy 'Compose: docker-compose.yml': `docker-compose` process finished with exit code 1
答案 0 :(得分:0)
在将本地文件装入容器时,必须在开头添加.
或使用绝对路径。否则,如错误所示,Docker将假定它是一个命名卷。