Force share without Accept Email

Discuss your pilot or production implementation with other Zimbra admins or our engineers.
quietas
Outstanding Member
Outstanding Member
Posts: 368
Joined: Fri Sep 12, 2014 10:42 pm

Force share without Accept Email

Postby quietas » Wed Jun 04, 2008 10:55 am

I've been wondering if there is a clean way to create a calendar, doc folder, or whatnot, and as admin share that to all users without them having to click accept or even getting an email.
Basically I want all of my users to have access to a company wide calendar and documents. When I add a new user, I'd also like them to have access.
I know there you can add a user to a distribution list, but will new users get the share automatically or do I have to reshare it to the list. If so, would all the other users get the email also?


p24t
Outstanding Member
Outstanding Member
Posts: 406
Joined: Fri Sep 12, 2014 10:28 pm

Force share without Accept Email

Postby p24t » Wed Jun 04, 2008 11:26 am

I don't know of a way to do that from the GUI, but you can use zmmailbox and mount things however you want.
I script my user creation so I can automatically add shares etc to them.
quietas
Outstanding Member
Outstanding Member
Posts: 368
Joined: Fri Sep 12, 2014 10:42 pm

Force share without Accept Email

Postby quietas » Wed Jun 04, 2008 11:38 am

I don't suppose there are any easy to use dirt simple one line scripts? My boss is not Linux CLI friendly and I am lazy =)
chauvetp
Outstanding Member
Outstanding Member
Posts: 350
Joined: Fri Sep 12, 2014 11:28 pm

Force share without Accept Email

Postby chauvetp » Wed Jun 04, 2008 12:54 pm

The command below will do what you want to. Its only a one line script if the given variables don't change;
zmmailbox -z -m destination-account@zmail.servername createMountpoint /MountName source-account@zmail.servername /SourceFolder
So if you have an account 'admin@zimbra.servername' and you want to share a folder on it named "Stuff" to 'user1@zimbra.servername' (and call it SharedStuff on that account)
zmmailbox -z -m user1@zimbra.servername createMountpoint /SharedStuff admin@zimbra.servername /Stuff
I use it to push a shared address book as part of my account creation scripts.
p24t
Outstanding Member
Outstanding Member
Posts: 406
Joined: Fri Sep 12, 2014 10:28 pm

Force share without Accept Email

Postby p24t » Wed Jun 04, 2008 1:29 pm

If you want a script to create users, here's one for you. Run it as the zimbra user, and you need Ruby installed. (sorry, that's what I use)
Just run it, and pass 4 arguments: username, password, first name, last name
#!/usr/bin/ruby
user = ARGV[0]

pass = ARGV[1]

fname = ARGV[2]

lname = ARGV[3]
system "zmprov ca #{user}@domain.com #{pass} givenName #{fname} sn #{lname} displayName '#{fname} #{lname}'"

system "zmmailbox -z -m #{user}@domain.com createMountpoint --color blue --view appointment "/Company Calendar" company@domain.com "/Calendar""

system "zmmailbox -z -m #{user}@domain.com createMountpoint --color blue --view contact "/Company Contacts" company@domain.com "/Contacts""

system "zmprov addDistributionListMember company_wide@domain.com #{user}@domain.com"


The first line creates the account, the second mounts a shared calendar, third does a shared contact list, and the last adds it to a distribution list. Obviously tailor it for your setup. I have an account called "company" that handles the shared items. The mounts are called "Company Calendar" etc, and just "Calendar" on the account doing the sharing.
quietas
Outstanding Member
Outstanding Member
Posts: 368
Joined: Fri Sep 12, 2014 10:42 pm

Force share without Accept Email

Postby quietas » Wed Jun 04, 2008 3:27 pm

p24t, that looks like that would work well.
I wonder if it might be possible to build that into an admin extension or zimlet? It seems like passing 4 variables entered in boxes would be easy enough. Basically I'm trying to make this process as stupid proof as possible.

Return to “Administrators”

Who is online

Users browsing this forum: No registered users and 6 guests