Bug 209789

Summary: sysutils/ansible: add patch to fix cron module
Product: Ports & Packages Reporter: Dmitry Marakasov <amdmi3>
Component: Individual Port(s)Assignee: Dmitry Marakasov <amdmi3>
Status: Closed FIXED    
Severity: Affects Some People CC: brd, lifanov
Priority: --- Keywords: patch
Version: LatestFlags: lifanov: maintainer-feedback+
amdmi3: merge-quarterly?
Hardware: Any   
OS: Any   
Attachments:
Description Flags
Patch
none
fix crontab module lifanov: maintainer-approval+

Description Dmitry Marakasov freebsd_committer freebsd_triage 2016-05-27 10:46:15 UTC
Created attachment 170722 [details]
Patch

ansible `cron' module does not work correctly: when writing crontab, it passes arguments to crontab(1) in wrong order (`crontab <newcrontabfile> -u <user>' instead of `crontab -u <user> <newcrontabfile>'). This leads to rewriting root's crontab instead of appending user's. The fix was already upstreamed:

https://github.com/ansible/ansible-modules-core/pull/3750

but since it'll take some time to get into the release, it'd be nice to have it in the port right now. MFH candidate as well.
Comment 1 Nikolai Lifanov 2016-05-27 12:49:45 UTC
Created attachment 170725 [details]
fix crontab module

Please use this instead. It rebases the patch on ansible 2.1.0.0
and lists the patch and uses the EXTRA_PATCHES approach to avoid
modifying sysutils/ansible1.

Thanks for the fix! I had to do a similar thing with "at" module
a while ago.

In order to merge to stable, you can merge it together with r415910,
or, if you would prefer, add this one as a second line to EXTRA_PATCHES.
Comment 2 commit-hook freebsd_committer freebsd_triage 2016-06-11 00:49:56 UTC
A commit references this bug:

Author: brd
Date: Sat Jun 11 00:49:53 UTC 2016
New revision: 416699
URL: https://svnweb.freebsd.org/changeset/ports/416699

Log:
  sysutils/ansible: add patch to fix cron module

  PR:		209789
  Submitted by:	Dmitry Marakasov <amdmi3@FreeBSD.org>
  Submitted by:	Nikolai Lifanov <lifanov@mail.lifanov.com> (maintainer)
  Approved by:	bdrewery (implicit, mentor)

Changes:
  head/sysutils/ansible/Makefile
  head/sysutils/ansible/files/extra-patch-b5e012b
Comment 3 Brad Davis freebsd_committer freebsd_triage 2016-06-11 00:50:29 UTC
Committed, thank you for your submission!