quarkusio / quarkus

Quarkus: Supersonic Subatomic Java.
https://quarkus.io
Apache License 2.0
13.73k stars 2.67k forks source link

Quarkus Dev Services passes wrong volume path to Docker on Windows #39123

Closed w0pp closed 7 months ago

w0pp commented 7 months ago

Describe the bug

I was trying to map a volume into Dev Services for Database, but Quarkus Dev Services threw an exception and caused the app to stop.

I tried with these two properties - first with the colon unescaped, then escaped:

The first property threw this exception: java.nio.file.InvalidPathException: Illegal char <"> at index 0: "classpath The second property threw this exception: Could not start container: com.github.dockerjava.api.exception.InternalServerErrorException: Status 500: mount denied: the source path "/C:/quarkus-app/target/classes/init-db.sql:/docker-entrypoint-initdb.d/init-db.sql:ro,z" too many colons

Expected behavior

Actual behavior

How to Reproduce?

Steps to reproduce the behavior:

  1. Download the archive containing the reproducer: reproducer.zip
  2. Run quarkus dev

Output of uname -a or ver

Microsoft Windows [Version 10.0.22631.3155]

Output of java -version

openjdk version "17.0.6" 2023-01-17 OpenJDK Runtime Environment Temurin-17.0.6+10 (build 17.0.6+10) OpenJDK 64-Bit Server VM Temurin-17.0.6+10 (build 17.0.6+10, mixed mode, sharing)

Quarkus version or git rev

3.8.1

Build tool (ie. output of mvnw --version or gradlew --version)

Apache Maven 3.9.6 (bc0240f3c744dd6b6ec2920b3cd08dcc295161ae)

Additional information

No response

quarkus-bot[bot] commented 7 months ago

/cc @geoand (devservices), @stuartwdouglas (devservices)