[PUP-9697] Solaris Crontabs -> puppet resource cron only returns root account Created: 2019/05/09  Updated: 2019/07/16  Resolved: 2019/06/18

Status: Closed
Project: Puppet
Component/s: Functions
Affects Version/s: None
Fix Version/s: PUP 5.5.16

Type: Bug Priority: Normal
Reporter: Jason Stewart Assignee: Sebastian Miclea
Resolution: Fixed Votes: 0
Labels: resolved-issue-added
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template: PUP Bug Template
Team: Night's Watch
Story Points: 3
Sprint: PR - 2019-06-12, PR - 2019-06-25
Method Found: Needs Assessment
CS Priority: Reviewed
Release Notes: Bug Fix
Release Notes Summary: Fixed reading of crontabs using Puppet for Solaris 11. Now crontabs for all users are listed when running 'puppet resource cron'
QA Risk Assessment: Needs Assessment

 Description   

Puppet Version:2018.1.5
Puppet Server Version:
OS Name/Version: Solaris 11

Unable to get a cron job from crontab for another user using `puppet resource cron` or `crontab -l` Solaris 11.

This has been set with a .pp code through classification and it uses the `user` resource to set up the cron job. 

Example :

crontab -l -> returns only jobs in the root crontab file.

crontab -l username -> returns only cron jobs in the users crontab.

Puppet Resource Cron will only return the root crontab.

 

Desired Behavior:

When running a puppet resource cron it should return all crontabs

Actual Behavior:

Only the root accounts crontab is returned on Solaris 11.

 

Cron is created with pp code
  cron

{ 'my cron job':                         command => "my command",                          user => "someuser",                 }

 Comments   
Comment by Josh Cooper [ 2019/06/13 ]

Merged to puppet#5.5.x in https://github.com/puppetlabs/puppet/commit/6e60fbe0ca6a2314e2d9863295a350a85986cd3d
Merged to cron_core in https://github.com/puppetlabs/puppetlabs-cron_core/commit/c87086c52c75d2ebe21bb8082979b2127a8690d7

Generated at Thu Nov 14 10:45:55 PST 2019 using JIRA 7.7.1#77002-sha1:e75ca93d5574d9409c0630b81c894d9065296414.