#1  
Old 26th December 2011, 23:01
dgmufasa dgmufasa is offline
Member
 
Join Date: Oct 2011
Posts: 86
Thanks: 5
Thanked 1 Time in 1 Post
Default Changing group directories

Hello all,

I have a job that needs to run on every ftp/ssh user directory created under a website.

What would be nice is to do something like
1. Create group for batch user (ex: mygroup)
2. Create batch user -
3. Assign batch user to batch group
4. Create web user with ID web xxx group: mygroup
ex: chown webxxx.mygroup directory (of created web user)


How can this be done within ISPConfig? I know that functions like ftp_user_add will allow you to set the group during
creation - but - how does one create the group to start off with?


As of now, when directories are created, they have the following for user owner and group owner:

drwxr-xr-x 2 web529 client692 4096 Dec 21 13:11 M035370file
drwxr-xr-x 3 web529 client692 4096 Dec 21 13:11 M035370depo
drwx------ 3 web529 client692 4096 Dec 26 15:00 m035370depo


in this case, the group owner is : client692.

Can I change this so that the group owner is something else like : mygroup so it would read:

drwxr-xr-x 2 web529 mygroup 4096 Dec 21 13:11 M035370file
drwxr-xr-x 3 web529 mygroup 4096 Dec 21 13:11 M035370depo
drwx------ 3 web529 mygroup 4096 Dec 26 15:00 m035370depo

without it hurting the way ISPConfig would run?

TIA

Last edited by dgmufasa; 26th December 2011 at 23:50.
Reply With Quote
Sponsored Links
  #2  
Old 27th December 2011, 08:35
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 34,586
Thanks: 792
Thanked 4,983 Times in 3,903 Posts
Default

instaed of cahnging the permissions, better run the batch job as root cronjob. Changing the permissions in the way yo described above would make the system insecure and you will change the ispconfig sourcecode to do that.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #3  
Old 27th December 2011, 10:47
dgmufasa dgmufasa is offline
Member
 
Join Date: Oct 2011
Posts: 86
Thanks: 5
Thanked 1 Time in 1 Post
Default

Hello and thanks for the response.

Quick question:

Is it possible for a one user to belong to more than one group in ISPConfig 3? By "user", I mean a user that has an entry in /etc/passwd and has its group defined in /etc/group.

If so, how can this be accomplished?

There is a perl program that must be defined in /etc/postfix/master.cf

It is defined as a service.

runme unix - n n - - pipe
user=<what_kind_of_user> argv=/var/myhome/runme.pl ${user}

This service will put files in directories - but - the user needs to be one that can run throughout the system to put files in
certain directories (not all). This user - of course - is defined in /etc/passwd and has a group id as well.

The idea is to:
1. create a group
2. assign this user to the group
3. create other users in the system (who also have an entry in /etc/passwd)
4. Assign those users to the same group

Again, not all users will fall in this category, just some. What can I do to solve this problem in ISPConfig? In a Unix environment, I would do items 1-4 - but - what can I do in an ISPConfig 3 environment?

My thoughts are that things could remain like this:
drwxr-xr-x 2 web529 client692 4096 Dec 21 13:11 M035370file
drwxr-xr-x 3 web529 client692 4096 Dec 21 13:11 M035370depo
drwx------ 3 web529 client692 4096 Dec 26 15:00 m035370depo

but the service would still be able to run but the users (ex: M035370file and M035370depo) would be a part of *two* groups - client692 and the group created in step 1 above. More importantly, how can this be done thru the ISPConfig SOAP API?
TIA

Last edited by dgmufasa; 27th December 2011 at 11:00.
Reply With Quote
  #4  
Old 27th December 2011, 11:00
till till is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 34,586
Thanks: 792
Thanked 4,983 Times in 3,903 Posts
Default

Quote:
Again, not all users will fall in this category, just some. What can I do to solve this problem in ISPConfig? In a Unix environment, I would do items 1-4 - but - what can I do in an ISPConfig 3 environment?
Its the same in ispconfig. Create a new shell group with the groupadd command and then add all web users that shall be part of this group to the new group. Steps 3 and 4 are not nescessary as the users exist already.
__________________
Till Brehm
--
Get ISPConfig support and the ISPConfig 3 manual from ispconfig.org.
Reply With Quote
  #5  
Old 27th December 2011, 11:45
dgmufasa dgmufasa is offline
Member
 
Join Date: Oct 2011
Posts: 86
Thanks: 5
Thanked 1 Time in 1 Post
 
Default

Thanks again for the prompt reply

>> then add all web users that shall be part of this group to the new group
Can this be done thru an ISPConfig SOAP interface (in PHP)? If not, can you make a suggestion how it could be done?

TIA
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Dovecot v2 with ISPConfig 3 CSsab Installation/Configuration 13 13th September 2012 19:01
ISPConfig Users Permissions guimnk Installation/Configuration 14 14th April 2011 18:26
Webmin upgrade lishaw1968 Installation/Configuration 15 26th August 2010 15:23
Can't access to my website - after install problem pallermo Installation/Configuration 18 4th June 2010 13:29
chgrp error new user DKA General 15 28th July 2008 17:45


All times are GMT +2. The time now is 16:48.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.