Skip to content

Commit a096439

Browse files
committed
change perm on upgrade
Signed-off-by: Abhishek Kumar <[email protected]>
1 parent 68eb611 commit a096439

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

debian/cloudstack-management.postinst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ if [ "$1" = configure ]; then
5757
chgrp cloud ${CONFDIR}/${DBPROPS}
5858
chown -R cloud:cloud /var/log/cloudstack/management
5959
chown -R cloud:cloud /usr/share/cloudstack-management/templates
60+
find /usr/share/cloudstack-management/templates -type d -exec chmod 0770 {} \;
6061

6162
ln -sf ${CONFDIR}/log4j-cloud.xml ${CONFDIR}/log4j2.xml
6263

packaging/el8/cloud.spec

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -470,6 +470,8 @@ if [ -f %{_sysconfdir}/sysconfig/%{name}-management ] ; then
470470
fi
471471

472472
chown -R cloud:cloud /var/log/cloudstack/management
473+
chown -R cloud:cloud /usr/share/cloudstack-management/templates
474+
find /usr/share/cloudstack-management/templates -type d -exec chmod 0770 {} \;
473475

474476
systemctl daemon-reload
475477

@@ -610,9 +612,9 @@ pip3 install --upgrade /usr/share/cloudstack-marvin/Marvin-*.tar.gz
610612
%{_datadir}/%{name}-management/setup/*.sh
611613
%{_datadir}/%{name}-management/setup/server-setup.xml
612614
%{_datadir}/%{name}-management/webapp/*
613-
%dir %attr(0775, cloud, cloud) %{_datadir}/%{name}-management/templates
614-
%dir %attr(0775, cloud, cloud) %{_datadir}/%{name}-management/templates/systemvm
615-
%attr(0644, cloud, cloud) %{_datadir}/%{name}-management/templates/*
615+
%dir %attr(0770, cloud, cloud) %{_datadir}/%{name}-management/templates
616+
%dir %attr(0770, cloud, cloud) %{_datadir}/%{name}-management/templates/systemvm
617+
%attr(0644, cloud, cloud) %{_datadir}/%{name}-management/templates/systemvm/*
616618
%attr(0755,root,root) %{_bindir}/%{name}-external-ipallocator.py
617619
%attr(0755,root,root) %{_initrddir}/%{name}-ipallocator
618620
%dir %attr(0770,root,root) %{_localstatedir}/log/%{name}/ipallocator

0 commit comments

Comments
 (0)