Is there a way to use a date range with the cli? Specifically trying to extract a list of users with password expiration between next Monday and next Friday. The ipa user-find --password-expiration= is a literal equals. And it's really specific down to the second. Can do this with external scripting but if there's a way use ipa first, that's preferred.
Jim Kinney via FreeIPA-users wrote:
Is there a way to use a date range with the cli? Specifically trying to extract a list of users with password expiration between next Monday and next Friday. The ipa user-find --password-expiration= is a literal equals. And it's really specific down to the second. Can do this with external scripting but if there's a way use ipa first, that's preferred.
Not with the ipa cli. You'll need to use ldapsearch.
Alternatively you may want to look at ipa-epn. It does exactly this and will send e-mail notifications. You can use the --dry-run to get the list of users if you're prefer.
rob
ipa-epn doesn't ship with IdM I don't think?
On July 19, 2022 3:23:36 PM EDT, Rob Crittenden rcritten@redhat.com wrote:
Jim Kinney via FreeIPA-users wrote:
Is there a way to use a date range with the cli? Specifically trying
to
extract a list of users with password expiration between next Monday
and
next Friday. The ipa user-find --password-expiration= is a literal equals. And it's really specific down to the second. Can do this with external scripting but if there's a way use ipa first, that's
preferred.
Not with the ipa cli. You'll need to use ldapsearch.
Alternatively you may want to look at ipa-epn. It does exactly this and will send e-mail notifications. You can use the --dry-run to get the list of users if you're prefer.
rob
Ah. It's in the client package. Servers are rhel, but the clients here are sles.
On July 19, 2022 3:23:36 PM EDT, Rob Crittenden rcritten@redhat.com wrote:
Jim Kinney via FreeIPA-users wrote:
Is there a way to use a date range with the cli? Specifically trying
to
extract a list of users with password expiration between next Monday
and
next Friday. The ipa user-find --password-expiration= is a literal equals. And it's really specific down to the second. Can do this with external scripting but if there's a way use ipa first, that's
preferred.
Not with the ipa cli. You'll need to use ldapsearch.
Alternatively you may want to look at ipa-epn. It does exactly this and will send e-mail notifications. You can use the --dry-run to get the list of users if you're prefer.
rob
Hi, ipa-epn is a bonus after upgrade from IPA 4.6 ! It will eventually replace my clumsy scripts. But - is is possible to get email variable in the ipa-epn template? Do I need to hack /usr/lib/python3.9/site-packages/ipaclient/install/ipa_epn.py for that?
With kind regards, Ivars
On 19 Jul 2022, at 22:23, Rob Crittenden via FreeIPA-users freeipa-users@lists.fedorahosted.org wrote:
Jim Kinney via FreeIPA-users wrote:
Is there a way to use a date range with the cli? Specifically trying to extract a list of users with password expiration between next Monday and next Friday. The ipa user-find --password-expiration= is a literal equals. And it's really specific down to the second. Can do this with external scripting but if there's a way use ipa first, that's preferred.
Not with the ipa cli. You'll need to use ldapsearch.
Alternatively you may want to look at ipa-epn. It does exactly this and will send e-mail notifications. You can use the --dry-run to get the list of users if you're prefer.
rob _______________________________________________ FreeIPA-users mailing list -- freeipa-users@lists.fedorahosted.org To unsubscribe send an email to freeipa-users-leave@lists.fedorahosted.org 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/freeipa-users@lists.fedorahoste... Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure
Ivars Strazdins via FreeIPA-users wrote:
Hi, ipa-epn is a bonus after upgrade from IPA 4.6 ! It will eventually replace my clumsy scripts. But - is is possible to get email variable in the ipa-epn template? Do I need to hack /usr/lib/python3.9/site-packages/ipaclient/install/ipa_epn.py for that?
You'd need to hack the script and potentially the template.
If you want this available by default please open a ticket at https://pagure.io/freeipa/new_issue
If you are going to make the change yourself anyway and want to contribute it you can create a PR at https://github.com/freeipa/freeipa
thanks
rob
With kind regards, Ivars
On 19 Jul 2022, at 22:23, Rob Crittenden via FreeIPA-users <freeipa-users@lists.fedorahosted.org mailto:freeipa-users@lists.fedorahosted.org> wrote:
Jim Kinney via FreeIPA-users wrote:
Is there a way to use a date range with the cli? Specifically trying to extract a list of users with password expiration between next Monday and next Friday. The ipa user-find --password-expiration= is a literal equals. And it's really specific down to the second. Can do this with external scripting but if there's a way use ipa first, that's preferred.
Not with the ipa cli. You'll need to use ldapsearch.
Alternatively you may want to look at ipa-epn. It does exactly this and will send e-mail notifications. You can use the --dry-run to get the list of users if you're prefer.
rob _______________________________________________ FreeIPA-users mailing list -- freeipa-users@lists.fedorahosted.org mailto:freeipa-users@lists.fedorahosted.org To unsubscribe send an email to freeipa-users-leave@lists.fedorahosted.org mailto:freeipa-users-leave@lists.fedorahosted.org 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/freeipa-users@lists.fedorahoste... Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure
FreeIPA-users mailing list -- freeipa-users@lists.fedorahosted.org To unsubscribe send an email to freeipa-users-leave@lists.fedorahosted.org 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/freeipa-users@lists.fedorahoste... Do not reply to spam on the list, report it: https://pagure.io/fedora-infrastructure
freeipa-users@lists.fedorahosted.org