Ask Your Question
0

validate_absolute_path gives me error.

asked 2016-06-03 14:49:45 -0500

puppetamateur gravatar image

I was given a working manifest that had validateabsolutepath($install_dir)

when I try to run the manifest, it gives me the following error:

Error: Evaluation Error: Unknown function: 'validateabsolutepath

why? if i remove the code, it works perfectly fine but my supervisor wants me to use the code. how do I fix the problem?

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2016-06-03 19:50:42 -0500

DarylW gravatar image

validate_absolute_path is a method from the stdlib module...

https://forge.puppet.com/puppetlabs/s...absolutepath

It will work if you have that module on your path. If you are testing your module in isolation, make sure it is in your modulepath... ( --modulepath /etc/puppet/modules/ ) etc... after having installed it (sudo puppet module install puppetlabs-stdlib

Install the stdlib module, and it should work. You can check if you have it installed with sudo puppet module list.

ubuntu:~$ sudo puppet module list
/etc/puppetlabs/code/environments/production/modules
├── daw-hello (v0.0.1)
├── deric-mesos (v0.7.1)
├── garethr-docker (v5.2.0)
├── jfryman-nginx (v0.3.0)
├── praekeltfoundation-marathon (v0.4.1)
├── puppetlabs-apt (v2.2.2)
├── puppetlabs-concat (v2.1.0)
├── puppetlabs-stdlib (v4.11.0)
└── stahnma-epel (v1.2.2)
/etc/puppetlabs/code/modules
└── daw-hello (v0.0.1)
/opt/puppetlabs/puppet/modules (no modules installed)
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2016-06-03 14:49:45 -0500

Seen: 125 times

Last updated: Jun 03 '16