Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cachedir setting is not idempotent #351

Closed
vchepkov opened this issue Mar 18, 2017 · 4 comments
Closed

cachedir setting is not idempotent #351

vchepkov opened this issue Mar 18, 2017 · 4 comments

Comments

@vchepkov
Copy link
Contributor

'puppet apply' and 'puppet agent' produce different results for the same code:

 Notice: /Stage[main]/R10k::Config/File[r10k.yaml]/content: 
--- /etc/puppetlabs/r10k/r10k.yaml	2017-03-18 18:42:23.732745000 +0000
+++ /tmp/puppet-file20170318-18579-18zu7r3	2017-03-18 18:46:56.205745000 +0000
@@ -1,5 +1,5 @@
 ---
-:cachedir: /opt/puppetlabs/puppet/cache/r10k
+:cachedir: /opt/puppetlabs/server/data/puppetserver/r10k
 :sources:
   puppet:
     basedir: /etc/puppetlabs/code/environments
@vchepkov
Copy link
Contributor Author

This could be a quirk of puppetserver and the fact that it doesn't honor settings of vardir in puppet.conf and instead using master-var-dir from puppetserver.conf, therefore $settings::vardir are different.

@rnelson0
Copy link
Member

I think that's probably the case. Can you confirm which of cachedir belongs to which command?

@vchepkov
Copy link
Contributor Author

The top one is for puppet apply, bottom for puppetserver
I see this changed back and forward when PE installer is running, since it's using 'puppet apply' and then reverts it when puppetserver compiles catalog.

@vchepkov
Copy link
Contributor Author

puppetlabs-stdlib provides a fact - $::puppet_vardir, it can be used instead of $settings::vardir, IMHO

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants