/[smeserver]/rpms/smeserver-yum/sme10/smeserver-yum-2.6.0-bz11180-yum-dbupdate-systemd.patch
ViewVC logotype

Annotation of /rpms/smeserver-yum/sme10/smeserver-yum-2.6.0-bz11180-yum-dbupdate-systemd.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.4 - (hide annotations) (download)
Wed Dec 9 05:30:35 2020 UTC (3 years, 7 months ago) by jpp
Branch: MAIN
Changes since 1.3: +2 -3 lines
* Tue Dec 08 2020 Jean-Philipe Pialasse <tests@pialasse.com> 2.6.0-42.sme
- move yum upate db service to systemd [SME: 11180]

1 jpp 1.1 diff -Nur smeserver-yum-2.6.0.old/createlinks smeserver-yum-2.6.0/createlinks
2     --- smeserver-yum-2.6.0.old/createlinks 2020-12-08 22:55:14.254000000 -0500
3     +++ smeserver-yum-2.6.0/createlinks 2020-12-08 23:28:27.655000000 -0500
4 jpp 1.4 @@ -21,18 +21,22 @@
5 jpp 1.1
6     # yum-update-dbs is launched by smeserver yum plugin,
7     # it isnot needed anymore in install remove and update events
8     -for ( qw(modify) )
9     -{
10     - event_link("yum-update-dbs", "yum-$_", "90");
11     -}
12     +#for ( qw(modify) )
13     +#{
14     +# event_link("yum-update-dbs", "yum-$_", "90");
15     +#}
16    
17     for ( qw(bootstrap-console-save yum-update smeserver-yum-update) )
18     {
19     event_link("yum-import-keys", $_, "10");
20     }
21    
22     -safe_symlink("once", "root/etc/e-smith/events/local/services2adjust/yum");
23     +safe_symlink("restart", "root/etc/e-smith/events/local/services2adjust/yum");
24    
25     +my $event= "smeserver-yum-update";
26     +# systemd-specific action mandatory for this package-update event
27     +event_link("systemd-reload", $event, "89");
28     +event_link("systemd-default", $event, "88");
29    
30     #--------------------------------------------------
31     # functions for manager panel
32     diff -Nur smeserver-yum-2.6.0.old/root/etc/cron.daily/smeserver-yum smeserver-yum-2.6.0/root/etc/cron.daily/smeserver-yum
33     --- smeserver-yum-2.6.0.old/root/etc/cron.daily/smeserver-yum 2008-10-07 10:25:45.000000000 -0400
34     +++ smeserver-yum-2.6.0/root/etc/cron.daily/smeserver-yum 2020-12-08 23:24:30.963000000 -0500
35     @@ -23,5 +23,5 @@
36    
37     [ $yum_status = 'enabled' ] || exit 0
38    
39     -/usr/bin/sv o /service/yum
40     +/usr/bin/systemctl restart yum.service
41    
42     diff -Nur smeserver-yum-2.6.0.old/root/etc/e-smith/events/actions/yum-update-dbs smeserver-yum-2.6.0/root/etc/e-smith/events/actions/yum-update-dbs
43     --- smeserver-yum-2.6.0.old/root/etc/e-smith/events/actions/yum-update-dbs 2005-09-25 22:30:54.000000000 -0400
44     +++ smeserver-yum-2.6.0/root/etc/e-smith/events/actions/yum-update-dbs 2020-12-08 23:17:10.008000000 -0500
45     @@ -21,5 +21,5 @@
46     # XXX - FIXME - We should be able to do this with a link
47     # /etc/e-smith/events/local/services2adjust/yum -> once
48     # but that never seems to terminate
49     -exec /usr/local/bin/svc -o /service/yum
50 jpp 1.4 +exec /usr/bin/systemctl restart yum.service &
51 jpp 1.1
52     diff -Nur smeserver-yum-2.6.0.old/root/sbin/e-smith/check4updates smeserver-yum-2.6.0/root/sbin/e-smith/check4updates
53     --- smeserver-yum-2.6.0.old/root/sbin/e-smith/check4updates 2020-12-08 22:55:14.233000000 -0500
54     +++ smeserver-yum-2.6.0/root/sbin/e-smith/check4updates 2020-12-08 23:07:22.069000000 -0500
55     @@ -23,7 +23,7 @@
56     /usr/sbin/yum-cron /etc/yum/yum-cron.conf >> $TMPFILE
57     #cat $TMP1 >> $TMPFILE
58     # we have updates, let's inform the server-manager
59     - /usr/bin/sv o yum
60     + /usr/bin/systemctl restart yum.service
61    
62     fi
63    
64     diff -Nur smeserver-yum-2.6.0.old/root/usr/lib/systemd/system/yum.service smeserver-yum-2.6.0/root/usr/lib/systemd/system/yum.service
65     --- smeserver-yum-2.6.0.old/root/usr/lib/systemd/system/yum.service 1969-12-31 19:00:00.000000000 -0500
66     +++ smeserver-yum-2.6.0/root/usr/lib/systemd/system/yum.service 2020-12-08 23:06:03.287000000 -0500
67     @@ -0,0 +1,13 @@
68     +[Unit]
69     +Description=Yum db updater for Koozali SME Server
70     +After=network-pre.target networking.service sme-server.target
71     +
72     +[Service]
73     +Type=oneshot
74     +ExecStartPre=/sbin/e-smith/service-status yum
75     +ExecStart=/sbin/e-smith/yum_update_dbs
76     +RemainAfterExit=yes
77     +
78 jpp 1.3 +[Install]
79 jpp 1.1 +# do not install with sme-server.target, this service will be launched by others
80     +# including Koozali SME Server local.service

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed