Skip to content
Advertisement

Tag: puppet

retrieve fact info based on variable in puppet

I have these facts: So with the main_ip fact I need to retrieve the interface that host it. I have try the following to compare the ip: but I cannot retrieve the value of the fact with the variable i’m giving… Can you please advice me how to find the value of the fact with the variable information in puppet?

Puppet – How to purge a directory

A bit of a Puppet newbie here. I am trying to recursively purge all files and directories under /var/www except keep one file present (/var/www/html/appicon.ico). This is my code: The code does appear to purge all files and directories, except for other files under /var/www/html. Any thoughts what I am doing wrong here or how this can be done properly?

Can resource attributes depend on file-presence?

I’m writing a module, that will provide for mirrored yum-repositories on our network. The single server will host the mirrors offering them to other hosts (and itself). I have a problem with the initial chicken-and-egg — the first download may not happen for a while, but, if I enable a new repository before the mirroring script for it finishes the

Puppet exec with command mkdir -p does not fail but does not create folder

I’m running this simple puppet code on Ubuntu 14.04 machines, to create folders according to a comma-separated list of paths: This resource definition is used as follows (in this case – just a single folder, no commas, other modules do need this “split” logic): When I run it, I see the following log line, indicating that the exec command was

unable to install puppetserver on ec2 ubuntu instance error: Some packages could not be installed

I am trying to install Puppet server on an EC2 Ubuntu instance: If I try to install puppet-common: I tried purging puppet-common and reinstalling it. I have also tried sudo apt-get upgrade. Any help will be appreciated. Thanks. Answer Have you enabled the PuppetLabs package repositories? Depending on the version of Ubuntu your on, you should do something like this:

Puppet referring to a module inside a module

I’m using Puppet 3.5.1 on Linux 6 machine. I have a local module “A” that includes a sub-module “B”. Such that sub-module “B” is located in “/etc/puppet/modules/A/modules/B”. I refer to sub-module “B” in my module “A” classes: (/etc/puppet/modules/A/manifest/init.pp file) B is then not reference any were else. When I start up puppet master and the puppet agent, I get the

Managing a user password for linux in puppet

I need to create a test user with a password using puppet. I’ve read that puppet cannot manage user passwords in a generic cross-platform way, which is a pity. I am doing this for Red Hat Enterprise Linux Server release 6.3. I do as follows: puppet updates the password of the user, but Linux says login/pwd incorrect when I try

Advertisement