Displaying 20 results from an estimated 10000 matches similar to: "if file exists"
2007 May 01
8
Custom functions and facts
Hello!
I''ve been trying to use facts from Facter in a custom function. I''ve
been following Matthew''s entry in the wiki
(http://www.reductivelabs.com/trac/puppet/wiki/WritingYourOwnFunctions).
What i''m seeing is that Facter[''fqdn''].value is always returning the
fqdn of the puppetmaster host. I was expecting the fqdn of the client
host.
2006 Sep 29
7
Facts load by puppet -factsync question
fact loads:
I use facter to search the rsync path and then i write this sudoers line:
Cmnd_Alias BACKUPCOMMANDS = /usr/bin/rsync
I call puppet like this:
puppetd --factsync --server=xxx.yyy.61.131 --waitforcert 60 --test
the recipe is:
sudoensure_line { sudobackupcommands:
ligne => "Cmnd_Alias BACKUPCOMMANDS =
$rsyncpath",
2008 Dec 04
4
puppetmaster built via puppetd
hi,
i''m trying to set up my puppetmaster infrastructure with multiple
puppetservers behind load balancers in each of our datacenters. i''m
using 0.24.6. i''ve read the howto on puppet scalability, and i think
i''ve got the ssl config working correct, but i''m noticing that when
puppetd is used to build a puppetmaster, some of the files in $vardir/
ssl
2009 Dec 21
5
custom fact and environment variable
Hello,
I''m trying to add an environment variable as fact like this :
#export $FACTER_test="infof"
#facter | grep test
test => infof
But my fact don''t synchronize with puppet master. I don''t see it in /
var/puppet/yaml/clientfile.yaml
If I want this works, I''ve need to start puppet like this :
#puppetd -vt --factsync
but factsync''s
2007 Dec 10
4
Results from testing our manifests, functions and types against HEAD
Hi Luke and other people working on 0.24. I hope this is constructive.
So, I have our configuration working against a checkout from git as of
last night.
Subject to (sorry, here''s the big but :)
* external_nodes script is not being called (#951)
* Custom types aren''t working unless I drop them into
$rubysitedir/puppet/{type,provider}. Previously they worked in
2007 Jan 10
7
Problem adding facts ...
I have created my first ''fact'', first attempt at Ruby too, and
configured the fileserver to server it but when a Fedora (5 or 6)
client sync''s puppetd appears to hang. CentOS clients sync and use the
new fact fine.
Find attached the fact file and the output from ''puppetd --debug
--factsync'' on a FC5 client is below. This is a 0.20.1 client and
2007 Jul 17
5
Recommended way to set $FACTERLIB?
Is there a recommended way to set $FACTERLIB so that Puppet will be able
to access custom facts when running as a Red Hat service?
If I export $FACTERLIB=/var/puppet/facts and then run Puppet manually I
have no problems, but I''m not sure how I should be setting $FACTERLIB
when Puppet is running automatically.
Cheers,
James
2006 Sep 15
4
before everything
I have some facter file to distribute before running puppet on the platform.
The problem is :
how can i send the facter local.rb file so the rest of the .pp file take
into account the new facts created ?
ex: i have sudopath as a facter fact and one sudoers class that need
that sudopath to work. How do you model that ?
it seems puppet would have to rerun after the new local.rb is downloaded
2008 May 30
2
pluginsync factsync etc
Hi,
When starting puppet on a new machine, (or when the $vardir/lib is empty)
puppet will not run the facts, it will only copy them.
on the second time puppet runs, it works quiet well:
on the client its defined:
[main]
pluginsync = true
pluginsource = puppet://$server/plugins
plugindest = $vardir/lib/puppet
factpath = $vardir/lib/puppet/facter
[puppetd]
factsync = true
I also tried with
2007 Dec 03
3
certificate issue with Branch Testing
Hello All,
I''m using the "Branch Testing" approach documented at
https://reductivelabs.com/trac/puppet/wiki/BranchTesting and am seeing
an issue with certificates.
On all clients, I can run puppetd --masterport=8141 successfully but see
the following error when I run against the default (8140) port:
err: Could not retrieve configuration: Certificates were not trusted:
2007 Mar 26
3
Basic help with imports and includes
Do any of you good people have a moment to help me out with my basic
Puppet language skills, I''m a little new around here and getting an error
I don''t yet understand.
I have an RHEL4 Puppetmaster happily controlling the permissions of
/etc/sudoers on an RHEL5 and SolarisX86 client.
My actual environment consists of several systems in several locations.
All systems need the
2007 Feb 07
2
Writing your own functions
In case anyone is interested in extending the Puppetmaster by writing new
functions, I''ve written up some notes on how to do it, gleaned from my own
experience earlier today:
http://reductivelabs.com/trac/puppet/wiki/WritingYourOwnFunctions
Corrections from people who''ve done it before, or who are wanting to do it,
as to correctness, clarity, or whatever, are appreciated. And
2007 Jun 01
1
Puppet starting before network is up
Lots of my puppet hosts have DHCP-assigned addresses. I''ve found, at
least in Debian 4.0, that puppetd will often start up before the network
interfaces are all up and running, and therefore it can''t contact the
puppetmaster. When that happens, puppet exits immediately. I''m hacking
around the problem with the following content in /etc/default/puppet,
but
2007 Apr 30
25
escape regex code
hello,
i wondered if it would not be interesting to have some filters
function in puppet like
filter_integer(), filter_prelregex, filter_text, filter_email or such
so we can validate and make our defines a little more foolproof :)
i particulary see filter_regex as usefull in quite a lot of exec that
manipulates text files. What do you think about this ?
--
Cordialement,
Ghislain
2010 Nov 10
4
Custom facts in current and old environments
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
Hello,
I read that there is several problems about custom facts on this list.
However, none is serving my task exactly so I start another. (Topic
»custom facts in legacy puppet 0.24.[89]« is the might be the same issue
but that gets no answer.)
My problem is that I have to serve clients with different versions of
puppet. The systems running ubuntu
2007 Apr 05
4
Preferred method for setting customer facts?
I''ve checked out the page on adding custom facts for Facter and I see
that there are a number of ways to do this. Is there a preferred method
of setting system-wide facts?
In this case, I''d like to set a "Location" fact which represents the
data centre a server is in.
Cheers,
James
*********************************************************************************
2006 Oct 11
5
Built In Puppet Variables Documentation
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
I''m just getting started with using Puppet, and from what I''ve seen I
really like it. However, I''m trying get started with slighly more
advanced things like templates but I''m running into a roadblock with not
knowing what built-in variables I have available to me. Is there
someplace this is documented?
2007 Nov 13
7
Exported resources & exec ?
Hi,
I''m sorry if that''s a FAQ, I also know exported resources are a still
experimental. So my problem might well be a design limitation of how
exported resources are working.
My issue: I''m trying to export a file resource that is created by an
exec block. The file is exported fine and collected fine but it is
always empty on the other host.
The puppet snippet:
class
2007 Nov 17
7
oddness with fileserver, facts and plugins sync
I''m working with a pretty simple config at the moment to track down some
issues I''m seeing with custom facts and plugins.
I have factsync = true (default locations)
and I have a simple fact in /var/lib/puppet/facts/
(actually it''s David''s netmask plugin)
my pp file I''m testing with contains only:
notice "netmask: ${netmask}"
puppet -v
2006 Nov 02
6
certificate not trusted
Hello,
I try to install puppet on freebsd 6.X. All is well but i cannot get
the certificte to install and be recognized. I run .19.3.
I run the puppetd --test --waitforcert 60
then sign
and then i got:
err: No certificate; running with reduced functionality.
info: Creating a new SSL key at
/usr/local/.aqadmin/puppet/conf/ssl/private_keys/xxxxxxxxxxxxxx.pem
info: Creating a new certificate