The Puppet Labs Issue Tracker has Moved:

This issue tracker is now in read-only archive mode and automatic ticket export has been disabled. Redmine users will need to create a new JIRA account to file tickets using See the following page for information on filing tickets with JIRA:

Feature #4938

Deprecate confusing symlink specification in 'ensure' for File resources

Added by Nigel Kersten about 5 years ago. Updated over 2 years ago.

Status:AcceptedStart date:10/05/2010
Priority:HighDue date:
Assignee:Charlie Sharpsteen% Done:


Target version:3.x
Affected Puppet version: Branch:
Keywords:usabililty customer

We've Moved!

Ticket tracking is now hosted in JIRA:


I generally think we’ve overloaded ‘ensure’ too much, and in the case of the File resource, it’s confusing.

Which of these do you think reads better? The latter works now, but only because anything not “file” or “directory” or “absent” or “present” falls down to a symlink.

file { "/tmp/foo":
  ensure => "/tmp/bar",

file { "/tmp/foo":
  ensure => symlink,
  target   => "/tmp/bar",

I propose we deprecate the current usage of ensure to overload symlinks, and make “symlink” a special word, just like “file” and “directory”.

Related issues

Related to Puppet - Bug #6808: Provide informative message when ensure => present, *and*... Closed 03/21/2011
Related to Puppet - Bug #5981: Puppet shouldn't overwrite symlinks when specifying conte... Accepted 01/23/2011
Duplicated by Puppet - Bug #4696: Typo in 'ensure' field of file resource results in confus... Duplicate 09/02/2010


#1 Updated by Nigel Kersten about 5 years ago

  • Status changed from Unreviewed to Accepted
  • Keywords set to usabililty

#2 Updated by Nigel Kersten over 4 years ago

  • Priority changed from Normal to High
  • Target version set to 2.7.x

#3 Updated by Nigel Kersten over 4 years ago

  • Target version changed from 2.7.x to 3.x

#4 Updated by Charlie Sharpsteen over 2 years ago

  • Assignee set to Charlie Sharpsteen

#5 Updated by Charlie Sharpsteen over 2 years ago

  • Keywords changed from usabililty to usabililty customer

Also available in: Atom PDF