smeserver-manager-panels/createlinks

55 lines
1.7 KiB
Plaintext
Raw Normal View History

2024-03-15 11:37:52 +01:00
#!/usr/bin/perl -w
use esmith::Build::CreateLinks qw(:all);
2024-03-15 11:37:52 +01:00
#--------------------------------------------------
# functions for manager
#--------------------------------------------------
my $mngrdir = '/usr/share/smanager';
2024-03-15 11:37:52 +01:00
# templates to expand
for ( qw( sme_core.css sme_main.css sme_menu.css styles.css ) )
2024-03-15 11:37:52 +01:00
{
templates2events("$mngrdir/themes/default/public/css/$_", qw(
bootstrap-console-save smeserver-manager-update
));
}
templates2events("$mngrdir/conf/srvmngr.conf",
qw( smeserver-manager-update smanager-theme-change smanager-modify bootstrap-console-save ));
2024-03-15 11:37:52 +01:00
templates2events("/etc/httpd/conf/httpd.conf",
qw( smeserver-manager-update smanager-modify ));
2024-03-15 11:37:52 +01:00
# services to launch on event
for my $event ( qw( smeserver-manager-update smanager-modify ) )
{
safe_symlink("restart",
"root/etc/e-smith/events/$event/services2adjust/smanager");
safe_symlink("reload",
"root/etc/e-smith/events/$event/services2adjust/httpd-e-smith");
}
2024-03-15 11:37:52 +01:00
safe_symlink("reload",
"root/etc/e-smith/events/smanager-theme-change/services2adjust/smanager");
2024-03-15 11:37:52 +01:00
safe_symlink("restart",
"root/etc/e-smith/events/smanager-refresh/services2adjust/smanager");
2024-03-15 11:37:52 +01:00
# actions to perform
for my $event ( qw( smeserver-manager-update smanager-refresh bootstrap-console-save ) )
{
event_link('navigation2-conf', "$event", '80');
event_link('routes2-conf', "$event", '80');
event_link('locales2-conf', "$event", '80');
}
2024-03-15 11:37:52 +01:00
event_link('systemd-default', "smeserver-manager-update", '88');
event_link('systemd-reload', "smeserver-manager-update", '89');
2024-03-15 11:37:52 +01:00
use esmith::Build::Backup qw(:all);
backup_includes("smeserver-manager", qw(
/usr/share/smanager/data
));