selinux-policy/update.sh
Hu 2112d5575b - Update to version 20240905:
* Allow coreos-installer-generator manage mdadm_conf_t files
  * Allow setsebool_t relabel selinux data files
  * Allow virtqemud relabelfrom virtqemud_var_run_t dirs
  * Use better escape method for "interface"
  * Allow init and systemd-logind to inherit fds from sshd
  * Allow systemd-ssh-generator read sysctl files
  * Sync modules.conf with Fedora targeted modules
  * Allow virtqemud relabel user tmp files and socket files
  * Add missing sys_chroot capability to groupadd policy
  * Label /run/libvirt/qemu/channel with virtqemud_var_run_t
  * Allow virtqemud relabelfrom also for file and sock_file
  * Add virt_create_log() and virt_write_log() interfaces
  - Sync modules-targeted-contrib.conf with Fedora targeted modules.conf

OBS-URL: https://build.opensuse.org/package/show/security:SELinux/selinux-policy?expand=0&rev=271
2024-09-09 08:08:07 +00:00

29 lines
648 B
Bash

#!/bin/sh
date=$(date '+%Y%m%d')
base_name_pattern='selinux-policy-*.tar.xz'
echo Update to $date
old_tar_file=$(ls -1 $base_name_pattern)
osc service manualrun
if [ "$1" = "full" ]; then
echo doing full update including container-selinux
rm -rf container-selinux
git clone --depth 1 https://github.com/containers/container-selinux.git
rm -f container.*
mv container-selinux/container.* .
rm -rf container-selinux
fi
# delete old files. Might need a better sanity check
tar_cnt=$(ls -1 $base_name_pattern | wc -l)
if [ $tar_cnt -gt 1 ]; then
echo delte old file $old_tar_file
rm "$old_tar_file"
osc addremove
fi
osc status