Delete file under dynamic folder ?

16 views
Skip to first unread message

Jérémy D

unread,
Jun 27, 2014, 4:40:29 AM6/27/14
to puppet...@googlegroups.com
Hello,

I need delete file : /usr/lib/zsh/4.3.17/zsh/newuser.so

But version will change and i don't find how to for this scenario

file { "/usr/lib/zsh/??/zsh/newuser.so":
        ensure => absent,
        require => Package[$packages],
     }

Anyone can help me ?

(sorry for my bad english)


jcbollinger

unread,
Jun 30, 2014, 8:58:22 AM6/30/14
to puppet...@googlegroups.com


This is an excellent reason to avoid installing unpackaged software.  Had the file in question been part of a package, then removing or updating the package would have taken care of the problem without any for you to sweat details such as this.

With the file not being part of a package, however, the first question to ask is how you would determine the appropriate version number if you had to do it manually.  Knowing that, the most idiomatic way to proceed would be to make a custom fact of it, and to use the fact value in a resource declaration such as you presented.


John

Reply all
Reply to author
Forward
0 new messages