mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-07 03:53:38 +00:00
packaging: Set default permissions for /var/log/frr to 0755
At the moment we set /var/log/frr permissions to 0750 (frr:frr), but the log file is 0640 (root:adm) (unless logrotated) and that doesn't allow adm group to even open the directory. Signed-off-by: Donatas Abraitis <donatas@opensourcerouting.org>
This commit is contained in:
parent
f5327fc339
commit
9bf7cb0b74
2
debian/frr.postinst
vendored
2
debian/frr.postinst
vendored
@ -16,7 +16,7 @@ adduser \
|
|||||||
frr
|
frr
|
||||||
usermod -a -G frrvty frr
|
usermod -a -G frrvty frr
|
||||||
|
|
||||||
mkdir -p /var/log/frr
|
mkdir -m 0755 -p /var/log/frr
|
||||||
mkdir -p /etc/frr
|
mkdir -p /etc/frr
|
||||||
|
|
||||||
|
|
||||||
|
@ -432,7 +432,8 @@ popd
|
|||||||
|
|
||||||
%install
|
%install
|
||||||
mkdir -p %{buildroot}%{_sysconfdir}/{frr,sysconfig,logrotate.d,pam.d,default} \
|
mkdir -p %{buildroot}%{_sysconfdir}/{frr,sysconfig,logrotate.d,pam.d,default} \
|
||||||
%{buildroot}%{_localstatedir}/log/frr %{buildroot}%{_infodir}
|
%{buildroot}%{_infodir}
|
||||||
|
mkdir -m 0755 -p %{buildroot}%{_localstatedir}/log/frr
|
||||||
make DESTDIR=%{buildroot} INSTALL="install -p" CP="cp -p" install
|
make DESTDIR=%{buildroot} INSTALL="install -p" CP="cp -p" install
|
||||||
|
|
||||||
# Remove this file, as it is uninstalled and causes errors when building on RH9
|
# Remove this file, as it is uninstalled and causes errors when building on RH9
|
||||||
@ -639,11 +640,11 @@ fi
|
|||||||
/usr/share/yang/*.yang
|
/usr/share/yang/*.yang
|
||||||
%if 0%{?frr_user:1}
|
%if 0%{?frr_user:1}
|
||||||
%dir %attr(751,%{frr_user},%{frr_user}) %{configdir}
|
%dir %attr(751,%{frr_user},%{frr_user}) %{configdir}
|
||||||
%dir %attr(750,%{frr_user},%{frr_user}) %{_localstatedir}/log/frr
|
%dir %attr(755,%{frr_user},%{frr_user}) %{_localstatedir}/log/frr
|
||||||
%dir %attr(751,%{frr_user},%{frr_user}) %{rundir}
|
%dir %attr(751,%{frr_user},%{frr_user}) %{rundir}
|
||||||
%else
|
%else
|
||||||
%dir %attr(750,root,root) %{configdir}
|
%dir %attr(750,root,root) %{configdir}
|
||||||
%dir %attr(750,root,root) %{_localstatedir}/log/frr
|
%dir %attr(755,root,root) %{_localstatedir}/log/frr
|
||||||
%dir %attr(750,root,root) %{rundir}
|
%dir %attr(750,root,root) %{rundir}
|
||||||
%endif
|
%endif
|
||||||
%{_infodir}/frr.info.gz
|
%{_infodir}/frr.info.gz
|
||||||
@ -918,7 +919,7 @@ sed -i 's/ -M rpki//' %{_sysconfdir}/frr/daemons
|
|||||||
- Add ability to show BGP routes from a particular table version
|
- Add ability to show BGP routes from a particular table version
|
||||||
- Add support for for RFC 8050 (MRT add-path)
|
- Add support for for RFC 8050 (MRT add-path)
|
||||||
- Add SNMP support for MPLS VPN
|
- Add SNMP support for MPLS VPN
|
||||||
- Add `show bgp summary wide` command to show more detailed output
|
- Add `show bgp summary wide` command to show more detailed output
|
||||||
on wide terminals
|
on wide terminals
|
||||||
- Add ability for peer-groups to have `ttl-security hops` configured
|
- Add ability for peer-groups to have `ttl-security hops` configured
|
||||||
- Add support for conditional Advertisement
|
- Add support for conditional Advertisement
|
||||||
|
@ -1752,7 +1752,7 @@ if __name__ == "__main__":
|
|||||||
|
|
||||||
elif args.reload:
|
elif args.reload:
|
||||||
if not os.path.isdir("/var/log/frr/"):
|
if not os.path.isdir("/var/log/frr/"):
|
||||||
os.makedirs("/var/log/frr/")
|
os.makedirs("/var/log/frr/", mode=0o0755)
|
||||||
|
|
||||||
logging.basicConfig(
|
logging.basicConfig(
|
||||||
filename="/var/log/frr/frr-reload.log",
|
filename="/var/log/frr/frr-reload.log",
|
||||||
|
Loading…
Reference in New Issue
Block a user