Re: [SOGo] Scripting resource creation
Hello Default calendar and addressbook are created on first login of user. On first login there are also other defaults and setting applied to the user. Because of that the first login is essential. It does not matter how, but the user has to login. In a script I would not use the webinterface. That is because you would need to handle HTML content yourself, and would rely on changing content on each new version. I would use the webdav access to the account. For example log in with the new users credentials and list the content of the personal Calendar. This would be empty, but you could be sure it was created. URL to use: https://${your.sogo.server}/SOGo/dav/"${yourNewUser}"/Calendar/personal Kind regards, Christian Mack Am 16.04.20 um 23:03 schrieb Thomas Winterstein (thomas.winterst...@rz.uni-augsburg.de): Hello, I'm having the same question/problem. We are too planning on using resources in sogo but I didn't yet find a comfortable way on how to manage them. Our goal is to automate as much as possible with a script. - creation of the ldap object - creation of the default calendar object - setting of acls ... But as Luca Olivetti pointed out there is no way to create the default calendar object with sogo-tool. I cannot find a sogo-tool option to create the default Calendar/personal for the user Without the default calendar, you can't set acls and therefore not use the resource. What is the common way on managing resources via script? Or to rephrase how do you manage your resources? Logging in as resource or using admin users is not an option for us. Kind regards Thomas Winterstein On 25.3.20 12:23, Luca Olivetti (l...@wetron.es) wrote: El 25/3/20 a les 11:14, Luca Olivetti ha escrit: Hello, I configured samba4 according to http://wiki.sogo.nu/ResourceConfiguration Now I have my resources in ldap and everything seems to be working. I'm trying to script the creation of resources by combining ldapadd (to create the resource in samba) and sogo-tool (to assign the ACLs). The problem is that after creating the user sogo-tool manage-acl doesn't work since the resource has not yet a calendar. I cannot find a sogo-tool option to create the default Calendar/personal for the user (I tried "sogo-tool checkup" which does nothing and "sogo-tool create-folder" which does not create the default calendar). The only way I found to create the calendar is to use curl --user "${USER}" "https://my.sogo.host/SOGo/so/${ID}/freebusy.ifb"; (where USER is the current user with access to SOGo and ID is the id of the resource). And I just found that it only works (i.e. creates the default calendar) if I give a WRONG password for a VALID user. An invalid user gives me forbidden, a valid password doesn't create the calendar (i see in the resulting vcalendar that ATTENDEE is "mailto:(null)"). That's strange. Isn't there a better way? Bye -- Christian Mack Universität Konstanz Kommunikations-, Informations-, Medienzentrum (KIM) Abteilung IT-Dienste Forschung und Lehre 78457 Konstanz +49 7531 88-4416 smime.p7s Description: S/MIME Cryptographic Signature
Re: [SOGo] Scripting resource creation
Hello, I'm having the same question/problem. We are too planning on using resources in sogo but I didn't yet find a comfortable way on how to manage them. Our goal is to automate as much as possible with a script. - creation of the ldap object - creation of the default calendar object - setting of acls ... But as Luca Olivetti pointed out there is no way to create the default calendar object with sogo-tool. I cannot find a sogo-tool option to create the default Calendar/personal for the user Without the default calendar, you can't set acls and therefore not use the resource. What is the common way on managing resources via script? Or to rephrase how do you manage your resources? Logging in as resource or using admin users is not an option for us. Kind regards Thomas Winterstein On 25.3.20 12:23, Luca Olivetti (l...@wetron.es) wrote: El 25/3/20 a les 11:14, Luca Olivetti ha escrit: Hello, I configured samba4 according to http://wiki.sogo.nu/ResourceConfiguration Now I have my resources in ldap and everything seems to be working. I'm trying to script the creation of resources by combining ldapadd (to create the resource in samba) and sogo-tool (to assign the ACLs). The problem is that after creating the user sogo-tool manage-acl doesn't work since the resource has not yet a calendar. I cannot find a sogo-tool option to create the default Calendar/personal for the user (I tried "sogo-tool checkup" which does nothing and "sogo-tool create-folder" which does not create the default calendar). The only way I found to create the calendar is to use curl --user "${USER}" "https://my.sogo.host/SOGo/so/${ID}/freebusy.ifb"; (where USER is the current user with access to SOGo and ID is the id of the resource). And I just found that it only works (i.e. creates the default calendar) if I give a WRONG password for a VALID user. An invalid user gives me forbidden, a valid password doesn't create the calendar (i see in the resulting vcalendar that ATTENDEE is "mailto:(null)"). That's strange. Isn't there a better way? Bye -- Thomas Winterstein http://www.rz.uni-augsburg.de/ Universität Augsburg, Rechenzentrum . Tel. (0821) 598-2068 86135 Augsburg .. Fax. (0821) 598-2028 -- users@sogo.nu https://inverse.ca/sogo/lists
Re: [SOGo] Scripting resource creation
El 25/3/20 a les 11:14, Luca Olivetti ha escrit: Hello, I configured samba4 according to http://wiki.sogo.nu/ResourceConfiguration Now I have my resources in ldap and everything seems to be working. I'm trying to script the creation of resources by combining ldapadd (to create the resource in samba) and sogo-tool (to assign the ACLs). The problem is that after creating the user sogo-tool manage-acl doesn't work since the resource has not yet a calendar. I cannot find a sogo-tool option to create the default Calendar/personal for the user (I tried "sogo-tool checkup" which does nothing and "sogo-tool create-folder" which does not create the default calendar). The only way I found to create the calendar is to use curl --user "${USER}" "https://my.sogo.host/SOGo/so/${ID}/freebusy.ifb"; (where USER is the current user with access to SOGo and ID is the id of the resource). And I just found that it only works (i.e. creates the default calendar) if I give a WRONG password for a VALID user. An invalid user gives me forbidden, a valid password doesn't create the calendar (i see in the resulting vcalendar that ATTENDEE is "mailto:(null)"). That's strange. Isn't there a better way? Bye -- Luca Olivetti Wetron Automation Technology http://www.wetron.es/ Tel. +34 93 5883004 (Ext.3010) Fax +34 93 5883007 -- users@sogo.nu https://inverse.ca/sogo/lists