private static String unencodeResourceURIToFilePath(@NotNull final String resource) {
        try {
            // Convert any url-encoded characters (e.g. spaces) back into unencoded form
            return URLDecoder
                .decode(resource.replaceAll("\\+", "%2B"), Charsets.UTF_8.name())
                .replaceFirst("jar:", "")
                .replaceFirst("file:", "")
                .replaceAll("!.*", "");
        } catch (UnsupportedEncodingException e) {
            throw new IllegalStateException(e);
        }
    }
Obtains a {@link MountableFile} corresponding to a file on the docker host filesystem.

@param path the path to the resource
@param mode octal value of posix file mode (000..777)
@return a {@link MountableFile} that may be used to obtain a mountable path
core/src/main/java/org/testcontainers/utility/MountableFile.java