[docker] force executbale bit on files inside bin directory. Fixes #358

This commit is contained in:
Andres Almiray
2021-08-13 20:32:29 +02:00
parent 366cd0ba55
commit 57dc0c92b9

View File

@@ -163,6 +163,13 @@ public final class FileUtils {
}
try (OutputStream o = Files.newOutputStream(file.toPath())) {
IOUtils.copy(in, o);
// TODO: make it a generic solution
// zipEntry.unixMode returns 0 most times even if the
// entry is executable
// https://github.com/jreleaser/jreleaser/issues/358
if ("bin".equalsIgnoreCase(file.getParentFile().getName())) {
grantExecutableAccess(file.toPath());
}
}
}
}