/[smeserver]/rpms/e-smith-proftpd/sme10/e-smith-proftpd-2.6.0-bz11106_11150_systemd_update_event.patch
ViewVC logotype

Contents of /rpms/e-smith-proftpd/sme10/e-smith-proftpd-2.6.0-bz11106_11150_systemd_update_event.patch

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


Revision 1.2 - (show annotations) (download)
Fri Dec 4 03:34:39 2020 UTC (3 years, 7 months ago) by jpp
Branch: MAIN
CVS Tags: e-smith-proftpd-2_6_0-7_el7_sme, e-smith-proftpd-2_6_0-8_el7_sme
Changes since 1.1: +2 -3 lines
* Thu Dec 03 2020 Jean-Philipe Pialasse <tests@pialasse.com> 2.6.0-7.sme
- execute systemd-reload before service adjust in events [SME: 11228]
- remove S95reset-unsavedflag [SME: 11229]

1 diff -urN e-smith-proftpd-2.6.0.old/createlinks e-smith-proftpd-2.6.0/createlinks
2 --- e-smith-proftpd-2.6.0.old/createlinks 2008-10-07 21:36:59.000000000 +0400
3 +++ e-smith-proftpd-2.6.0/createlinks 2020-11-27 22:32:57.824000000 +0400
4 @@ -3,14 +3,20 @@
5 use esmith::Build::CreateLinks qw(:all);
6
7 safe_symlink("../daemontools", "root/etc/rc.d/init.d/supervise/ftp");
8 -service_link_enhanced("ftp", "S85", "7");
9 +#service_link_enhanced("ftp", "S85", "7");
10 service_link_enhanced("ftp", "K25", "6");
11 service_link_enhanced("ftp", "K25", "0");
12
13 safe_symlink("proftpd", "root/var/service/ftp");
14
15 -templates2events("/etc/logrotate.d/proftpd", "bootstrap-console-save");
16 -templates2events("/etc/pam.d/ftp", "bootstrap-console-save");
17 +templates2events("/etc/logrotate.d/proftpd", qw(
18 + bootstrap-console-save
19 + e-smith-proftpd-update
20 + ));
21 +templates2events("/etc/pam.d/ftp", qw(
22 + bootstrap-console-save
23 + e-smith-proftpd-update
24 + ));
25 templates2events("/etc/ftpusers", qw(
26 bootstrap-console-save
27 network-create
28 @@ -18,6 +24,7 @@
29 remoteaccess-update
30 password-modify
31 user-lock
32 + e-smith-proftpd-update
33 ));
34
35 templates2events("/etc/proftpd.conf", qw(
36 @@ -34,7 +41,9 @@
37 network-create
38 network-delete
39 remoteaccess-update
40 - password-modify));
41 + password-modify
42 + e-smith-proftpd-update
43 + ));
44
45 foreach my $event (qw(
46 remoteaccess-update))
47 @@ -47,6 +56,7 @@
48 network-create
49 remoteaccess-update
50 network-delete
51 + e-smith-proftpd-update
52 ))
53 {
54 templates2events("/var/service/ftp/peers/0", $event);
55 @@ -60,4 +70,9 @@
56 safe_symlink("sigusr1", "root/etc/e-smith/events/$event/services2adjust/ftp");
57 }
58
59 +my $event = 'e-smith-proftpd-update';
60 +safe_symlink("restart", "root/etc/e-smith/events/$event/services2adjust/ftp");
61 +templates2events("/etc/systemd/system-preset/49-koozali.preset", $event);
62 +event_link("systemd-reload", $event, "89");
63 +
64 exit 0;
65 diff -urN e-smith-proftpd-2.6.0.old/root/usr/lib/systemd/system/ftp.service e-smith-proftpd-2.6.0/root/usr/lib/systemd/system/ftp.service
66 --- e-smith-proftpd-2.6.0.old/root/usr/lib/systemd/system/ftp.service 1970-01-01 04:00:00.000000000 +0400
67 +++ e-smith-proftpd-2.6.0/root/usr/lib/systemd/system/ftp.service 2020-11-27 22:41:01.703000000 +0400
68 @@ -0,0 +1,15 @@
69 +[Unit]
70 +Description=ftp (proftpd)
71 +After=network.target
72 +Conflicts=proftpd.service
73 +
74 +[Service]
75 +Type=oneshot
76 +ExecStartPre=/sbin/e-smith/service-status ftp
77 +ExecStart=/usr/bin/sv u /service/ftp
78 +ExecStop=/usr/bin/sv stop /service/ftp
79 +ExecReload=/usr/bin/sv t /service/ftp
80 +RemainAfterExit=yes
81 +
82 +[Install]
83 +WantedBy=sme-server.target
84 diff -urN e-smith-proftpd-2.6.0.old/root/usr/lib/systemd/system-preset/80-koozali-ftp.preset e-smith-proftpd-2.6.0/root/usr/lib/systemd/system-preset/80-koozali-ftp.preset
85 --- e-smith-proftpd-2.6.0.old/root/usr/lib/systemd/system-preset/80-koozali-ftp.preset 1970-01-01 04:00:00.000000000 +0400
86 +++ e-smith-proftpd-2.6.0/root/usr/lib/systemd/system-preset/80-koozali-ftp.preset 2020-11-27 22:24:16.950000000 +0400
87 @@ -0,0 +1 @@
88 +enable ftp.service

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