smeserver-update/createlinks
2024-03-25 17:44:36 -04:00

38 lines
1.1 KiB
Perl
Executable File

#!/usr/bin/perl -w
use esmith::Build::CreateLinks qw(:all);
use File::Basename;
use File::Path;
foreach my $file (qw(/etc/dnf/dnf.conf /etc/dnf/protected.d/smeserver.conf
/etc/yum.smerepos.d/sme-base.repo /etc/dnf/automatic.conf))
{
templates2events($file, qw(dnf-modify bootstrap-console-save smeserver-update-update));
}
templates2events("/etc/crontab", "dnf-modify");
for ( qw(install remove update) )
{
event_link("dnf-action", "dnf-$_", "20");
}
safe_symlink("restart", "root/etc/e-smith/events/dnf-modify/services2adjust/yum");
for ( qw(bootstrap-console-save dnf-update smeserver-update-update) )
{
event_link("rpm-import-keys", $_, "10");
}
my $event= "smeserver-update-update";
# systemd-specific action mandatory for this package-update event
event_link("systemd-reload", $event, "89");
event_link("systemd-default", $event, "88");
templates2events("/etc/rsyslog.conf",$event);
safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/rsyslog");
#--------------------------------------------------
# functions for manager panel
#--------------------------------------------------
panel_link("dnf", "manager");