Puppet: System Administration Automated

Support

Ticket #894 (closed enhancement: fixed)

Opened 1 year ago

Last modified 9 months ago

err: Cannot currently copy links - "links => manage" fails

Reported by: blueyoko Assigned to: community
Priority: normal Milestone: unplanned
Component: server Version: 0.23.2
Severity: normal Keywords:
Cc: Triage Stage: Accepted
Attached Patches: None Complexity: Unknown

Description (Last modified by luke)

Hi,

I am running puppet v.0.23.2 on Debian etch with apache2. The apache2 directory is the standard debian apache2 directory with symlinks in directories like /etc/apache2/sites-enabled linking to /etc/apache2/sites-available like so:

ls -lart modules/apache/files/example.com/apache2/sites-enabled/
lrwxrwxrwx 1 puppet puppet   49 2007-11-09 14:58 002-mine01.example.com -> ../sites-available/mine01.example.com.
lrwxrwxrwx 1 puppet puppet   42 2007-11-09 14:58 001-example.com -> ../sites-available/example.com
lrwxrwxrwx 1 puppet puppet   36 2007-11-09 14:58 000-default -> /etc/apache2/sites-available/default

When I run this syntax in an apache module:

file {  "/etc/apache2":
        source => "puppet://puppet-master.example.com/www-au/apache2",
        recurse => true,
        owner => "root",
        group => "root",
        links => follow,
}

symlinks are created as files like you'd expect.

when I use this(with an empty apache2 dir on the client):

file {  "/etc/apache2":
        source => "puppet://puppet-master.example.com/www-au/apache2",
        recurse => true,
        owner => "root",
        group => "root",
        links => manage,
}

I get this on the master for each file:

err: Cannot currently copy links

and this on the client for each file:

err: //basenode/webserver/apache2/File[/etc/apache2/mods-available/headers.load]/source: Could not describe /www-au/apache2/mods-available/headers.load: Cannot currently copy links
}}
Using the http://reductivelabs.com/trac/puppet/wiki/StyleGuide#symlinks fixes this issue
{{{
file { "/etc/apache2/mods-enabled/auth_basic.load":
        ensure => link,
        target => "/etc/apache2/mods-available/auth_basic.load",
}
}}}
but I was expecting the recursive copy to manage the symlinks.

Happy to provide further detail if required.

Change History

11/24/07 03:17:02 changed by luke

  • description changed.

11/24/07 03:21:10 changed by luke

  • stage changed from Unreviewed to Accepted.
  • type changed from defect to enhancement.
  • milestone set to unplanned.

02/24/08 01:06:47 changed by luke

  • status changed from new to closed.
  • resolution set to fixed.

Fixed in [ff97059].