Anton PalkoBrosov via FreeIPA-users wrote:
> So i simplified task
> Here is script
> from ipalib.plugins.user import user_add
> from ipalib import api, plugable
>
> def check(self,ldap,dn,entry_attrs,*keys,**options):
> with open('/home/freeipa/test.txt','a') as f:
> f.write('xxxxxx')
> user_add.register_post_callback(check)
>
> to a script file and test.txt files i added via ACL an RWX permission for
> user ipaapi
> creating new user in GUI - nothing added to file
>
> maybe some path issues?
> so freeipa works in Astra Linux, so maybe it has different path fo scripts
> which differs from default Debian deployemen....because by default there was
> no site-packages folder, but python 2.7 folder fas present science server
> deployement
> Can i manually specify path for extention scripts?
>
To see what is going on I'd suggest:
import logging
logger = logging.getLogger(__name__)
...
logger.debug("my post call back")
Create /etc/ipa/server.conf with the contents
[global]
debug = True
restart httpd
You'll get a LOT more output in the Apache error log.
I don't know how well the server runs on Debian derivatives. There is
basically only one heroic maintainer and IPA has a ton of moving parts.
You want to put your plugin in the same places as the other IPA plugins.
It doesn't currently look any place else.
rob
--
_______________________________________________
FreeIPA-users mailing list -- [email protected]
To unsubscribe send an email to [email protected]
Fedora Code of Conduct:
https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives:
https://lists.fedorahosted.org/archives/list/[email protected]
Do not reply to spam, report it:
https://pagure.io/fedora-infrastructure/new_issue