diff --git a/SPECS/mlocate-0.26.tar.xz b/SPECS/mlocate-0.26.tar.xz new file mode 100644 index 0000000..315d5f3 Binary files /dev/null and b/SPECS/mlocate-0.26.tar.xz differ diff --git a/SPECS/mlocate-run-updatedb b/SPECS/mlocate-run-updatedb new file mode 100644 index 0000000..7d3f2ac --- /dev/null +++ b/SPECS/mlocate-run-updatedb @@ -0,0 +1,4 @@ +#!/bin/sh + +nodevs=$(< /proc/filesystems awk '$1 == "nodev" && $2 != "rootfs" && $2 != "zfs" { print $2 }') +/usr/bin/updatedb -f "$nodevs" diff --git a/SPECS/mlocate-updatedb.service b/SPECS/mlocate-updatedb.service new file mode 100644 index 0000000..46efbd3 --- /dev/null +++ b/SPECS/mlocate-updatedb.service @@ -0,0 +1,13 @@ +[Unit] +Description=Update a database for mlocate + +[Service] +ExecStart=/usr/libexec/mlocate-run-updatedb +Nice=19 +IOSchedulingClass=2 +IOSchedulingPriority=7 + +PrivateTmp=true +PrivateDevices=true +PrivateNetwork=true +ProtectSystem=true diff --git a/SPECS/mlocate-updatedb.timer b/SPECS/mlocate-updatedb.timer new file mode 100644 index 0000000..9472537 --- /dev/null +++ b/SPECS/mlocate-updatedb.timer @@ -0,0 +1,10 @@ +[Unit] +Description=Updates mlocate database every day + +[Timer] +OnCalendar=daily +AccuracySec=24h +Persistent=true + +[Install] +WantedBy=timers.target diff --git a/SPECS/updatedb.conf b/SPECS/updatedb.conf new file mode 100644 index 0000000..8b0b8e1 --- /dev/null +++ b/SPECS/updatedb.conf @@ -0,0 +1,4 @@ +PRUNE_BIND_MOUNTS = "yes" +PRUNEFS = "9p afs anon_inodefs auto autofs bdev binfmt_misc cgroup cifs coda configfs cpuset debugfs devpts ecryptfs exofs fuse fuse.sshfs fusectl gfs gfs2 gpfs hugetlbfs inotifyfs iso9660 jffs2 lustre mqueue ncpfs nfs nfs4 nfsd pipefs proc ramfs rootfs rpc_pipefs securityfs selinuxfs sfs sockfs sysfs tmpfs ubifs udf usbfs ceph fuse.ceph" +PRUNENAMES = ".git .hg .svn .bzr .arch-ids {arch} CVS" +PRUNEPATHS = "/afs /media /mnt /net /sfs /tmp /udev /var/cache/ccache /var/lib/yum/yumdb /var/lib/dnf/yumdb /var/spool/cups /var/spool/squid /var/tmp /var/lib/ceph"