on new account creation, create automatically www, stats and backups directories to help users keep their account clean
This commit is contained in:
		
							parent
							
								
									1b9ed23260
								
							
						
					
					
						commit
						1b83f2db42
					
				
							
								
								
									
										10
									
								
								src/mem_add
								
								
								
								
							
							
						
						
									
										10
									
								
								src/mem_add
								
								
								
								
							|  | @ -27,9 +27,13 @@ $( = $); | |||
| 
 | ||||
| my $PTH="/var/alternc/html/".substr($name,0,1)."/".$name; | ||||
| 
 | ||||
| mkdir($PTH); | ||||
| chown(33, $uid, $PTH); | ||||
| system("/bin/chmod 02770 '$PTH'"); | ||||
| my @create_paths = ($PTH, $PTH . '/www', $PTH . '/stats', $PTH . '/backups'); | ||||
| 
 | ||||
| for my $p (@create_paths) { | ||||
|     mkdir($p); | ||||
|     chown(33, $uid, $p); | ||||
|     system("/bin/chmod 02770 '$p'"); | ||||
| } | ||||
| 
 | ||||
| 0; | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue
	
	 mlutfy
						mlutfy