Skip to content

Commit 38707e9

Browse files
authored
Update sudoers for cape user Nginx permissions
Added permissions for cape user to modify Nginx static file permissions.
1 parent 076eb14 commit 38707e9

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

installer/cape2.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1429,6 +1429,10 @@ if [ ! -f /etc/sudoers.d/cape ]; then
14291429
Cmnd_Alias CAPE_SERVICES = /usr/bin/systemctl restart cape-rooter, /usr/bin/systemctl restart cape-processor, /usr/bin/systemctl restart cape, /usr/bin/systemctl restart cape-web, /usr/bin/systemctl restart cape-dist, /usr/bin/systemctl restart cape-fstab, /usr/bin/systemctl restart suricata, /usr/bin/systemctl restart guac-web, /usr/bin/systemctl restart guacd
14301430
Cmnd_Alias UFW_STATUS = /usr/sbin/ufw status
14311431
${USER} ALL=(ALL) NOPASSWD:CAPE_SERVICES, UFW_STATUS
1432+
# Allow cape user to fix Nginx permissions for static files
1433+
${USER} ALL=(ALL) NOPASSWD: /usr/bin/chmod o+x ${CAPE_ROOT}
1434+
${USER} ALL=(ALL) NOPASSWD: /usr/bin/chmod o+x ${CAPE_ROOT}/web
1435+
${USER} ALL=(ALL) NOPASSWD: /usr/bin/chmod -R o+rX ${CAPE_ROOT}/web/static_collected/
14321436
EOF
14331437
fi
14341438
if [ ! -f /etc/sudoers.d/ip_netns ]; then

0 commit comments

Comments
 (0)