/[smeserver]/rpms/e-smith-ibays/sme10/e-smith-ibays-2.6.0-create_sess_folder_in_ibays.patch
ViewVC logotype

Annotation of /rpms/e-smith-ibays/sme10/e-smith-ibays-2.6.0-create_sess_folder_in_ibays.patch

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


Revision 1.3 - (hide annotations) (download)
Sun Jun 26 17:43:08 2016 UTC (7 years, 11 months ago) by unnilennium
Branch: MAIN
CVS Tags: e-smith-ibays-2_6_0-11_el7_sme, e-smith-ibays-2_6_0-12_el7_sme, e-smith-ibays-2_6_0-17_el7_sme, e-smith-ibays-2_6_0-10_el7_sme, e-smith-ibays-2_6_0-15_el7_sme, e-smith-ibays-2_6_0-16_el7_sme, e-smith-ibays-2_6_0-20_el7_sme, e-smith-ibays-2_6_0-18_el7_sme, e-smith-ibays-2_6_0-13_el7_sme, e-smith-ibays-2_6_0-9_el7_sme, e-smith-ibays-2_6_0-7_el7_sme, e-smith-ibays-2_6_0-19_el7_sme, e-smith-ibays-2_6_0-14_el7_sme, e-smith-ibays-2_6_0-8_el7_sme, e-smith-ibays-2_6_0-6_el7_sme, HEAD
Changes since 1.2: +5 -5 lines
* Sun Jun 26 2016 Jean-Philipe Pialasse <tests@pialasse.com> 2.6.0-6.sme
- as per comment 2 of bug 0600 instead of 0700 for perms [SME: 9621]

1 unnilennium 1.1 diff -Nur e-smith-ibays-2.6.0.old/root/etc/e-smith/events/actions/ibay-modify e-smith-ibays-2.6.0/root/etc/e-smith/events/actions/ibay-modify
2     --- e-smith-ibays-2.6.0.old/root/etc/e-smith/events/actions/ibay-modify 2016-06-23 02:57:56.838000000 -0400
3     +++ e-smith-ibays-2.6.0/root/etc/e-smith/events/actions/ibay-modify 2016-06-23 03:18:20.693000000 -0400
4     @@ -163,6 +163,10 @@
5 unnilennium 1.2 $tmpdir = ('/var/cache/e-smith/files/ibays/' . $ibay->key . '/tmp') if $tmpdir eq 'enabled';
6 unnilennium 1.1 mkdir $tmpdir unless (-d $tmpdir || $tmpdir eq "disabled");
7    
8     +my $sessdir = $ibay->prop('PHPSessionDir') || 'enabled';
9 unnilennium 1.2 +$sessdir = ('/var/cache/e-smith/files/ibays/' . $ibay->key . '/session') if $sessdir eq 'enabled';
10 unnilennium 1.1 +mkdir $sessdir unless (-d $sessdir || $sessdir eq "disabled");
11     +
12     chdir "/home/e-smith/files/ibays/$ibayName"
13     or ( $x = 255, warn "Could not chdir to /home/e-smith/files/ibays/$ibayName" );
14    
15     @@ -238,6 +242,13 @@
16     system ('/bin/chown', '-R', 'www:www' , $tmpdirperm);
17 unnilennium 1.3 system ('/bin/chmod', '0600' , $tmpdirperm );
18 unnilennium 1.1 }
19 unnilennium 1.3 + ##chmod 0600 ; chown www:www if session folder exists
20 unnilennium 1.2 + my $sessdirperm = (('/var/cache/e-smith/files/ibays/' . $ibay->key . '/session')||'');
21 unnilennium 1.1 + if ( -d $sessdirperm)
22     + {
23     + system ('/bin/chown', '-R', 'www:www' , $sessdirperm);
24 unnilennium 1.3 + system ('/bin/chmod', '0600' , $sessdirperm );
25 unnilennium 1.1 + }
26     }
27     }
28    
29     diff -Nur e-smith-ibays-2.6.0.old/root/etc/e-smith/events/actions/init-ibays e-smith-ibays-2.6.0/root/etc/e-smith/events/actions/init-ibays
30     --- e-smith-ibays-2.6.0.old/root/etc/e-smith/events/actions/init-ibays 2016-06-23 02:57:56.838000000 -0400
31     +++ e-smith-ibays-2.6.0/root/etc/e-smith/events/actions/init-ibays 2016-06-23 03:21:50.502000000 -0400
32     @@ -72,6 +72,7 @@
33     #Then we retrieve the name of the ebay
34     my $key = $ibay->key;
35     my $tmpdb = $ibay->prop('PHPTmpDir') || 'enabled';
36     + my $sessiondb = $ibay->prop('PHPSessionDir') || 'enabled';
37 unnilennium 1.2 my $path = (('/var/cache/e-smith/files/ibays/') . $key . '/tmp');
38 unnilennium 1.1
39     #we test the condition if /tmp exists or if it is disabled in the Ibay
40     @@ -79,6 +80,12 @@
41     {
42 unnilennium 1.3 mkdir $path, 0600 or warn "Could not create dir $path: $!";
43 unnilennium 1.1 chown $uid, $gid, $path or warn "Could not chown dir $path: $!";
44     + }
45     + #we test the condition if /session exists or if it is disabled in the Ibay
46     + unless (-d $path || $sessiondb eq "disabled")
47     + {
48 unnilennium 1.3 + mkdir $path, 0600 or warn "Could not create dir $path: $!";
49 unnilennium 1.1 + chown $uid, $gid, $path or warn "Could not chown dir $path: $!";
50     }
51     }
52    

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