Skip to content

installBootDist creates executables with wrong permission #14158

@occho

Description

@occho

With Gradle application plugin, installBootDist task is available to install distribution files.

When performing installBootDist, I observed the installed executables have wrong permission:

$ ./gradlew clean installBootDist

BUILD SUCCESSFUL in 1s
5 actionable tasks: 5 executed
$ ls -l build/install/initial-boot/bin/
total 24
-r-x-wSr-t  1 (xxx)  (xxx)  5207  8 21 19:19 initial
-r-x-wSr-t  1 (xxx)  (xxx)  2178  8 21 19:19 initial.bat
$ gstat -c "%a %n" ./build/install/initial-boot/bin/initial*
3525 ./build/install/initial-boot/bin/initial
3525 ./build/install/initial-boot/bin/initial.bat

Tested on mac.

The file permission is set to -r-x-wSr-t (0x755 in hex is 3525 in octal).
It should be like -rwxr-xr-x (0755, octal).

https://github.com/spring-projects/spring-boot/blob/v2.0.4.RELEASE/spring-boot-project/spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/plugin/ApplicationPluginAction.java#L83

Sample project

https://github.com/occho/gs-spring-boot/tree/filemode-bug-with-application-plugin/initial

Version tested

spring-boot-gradle-plugin: 2.0.4.RELEASE

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions