Skip to content

Commit

Permalink
Explicitly configure setgid for RPM and Dep packaging
Browse files Browse the repository at this point in the history
  • Loading branch information
breskeby committed Sep 29, 2023
1 parent b4e9388 commit 785b1ef
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion distribution/packages/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ def commonPackageConfig(String type, String architecture) {
configurationFile '/etc/elasticsearch/users_roles'
from("${packagingFiles}") {
dirMode 02750
setgid = true
into('/etc')
permissionGroup 'elasticsearch'
includeEmptyDirs true
Expand All @@ -194,6 +195,7 @@ def commonPackageConfig(String type, String architecture) {
from("${packagingFiles}/etc/elasticsearch") {
into('/etc/elasticsearch')
dirMode 02750
setgid = true
fileMode 0660
permissionGroup 'elasticsearch'
includeEmptyDirs true
Expand Down Expand Up @@ -240,7 +242,8 @@ def commonPackageConfig(String type, String architecture) {
createDirectoryEntry true
user u
permissionGroup g
dirMode mode
dirMode = mode
setgid = mode == 02750
}
}
copyEmptyDir('/var/log/elasticsearch', 'elasticsearch', 'elasticsearch', 02750)
Expand Down

0 comments on commit 785b1ef

Please sign in to comment.