Bug #668

Using File with ensure => directory fails if there's no parent directory

Added by Miguel Lourenco about 3 years ago. Updated about 3 years ago.

Status:Closed Start:
Priority:Normal Due date:
Assignee:Luke Kanies % Done:

0%

Category:-
Target version:-
Affected version:0.25.4 Branch:
Keywords:
Votes: 0

Description

This fails if the directory /var/local/sandbox does not exist:

file { “/var/local/sandbox/test”: ensure => directory }

I don’t know if it’s by choice (I would personally prefer that it would create the directory) or if it’s a bug, so I’m opening a ticket on it since it’s not documented.

Using mkdir -p would probably work, although I’m not sure about the permissions of the directories created in the path to the new one…

History

Updated by Luke Kanies about 3 years ago

  • Status changed from 1 to Closed
  • 7 set to duplicate

This is a duplicate of #86.

Also available in: Atom PDF