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

facts.d scripts not working when running puppet agent as a service #59

Open
ubellavance opened this issue Jun 30, 2017 · 4 comments
Open

Comments

@ubellavance
Copy link
Contributor

Logs:

start-puppet-agent: Fact file /var/lib/puppet/facts.d/get_extensions_details.php was parsed but returned an empty data set

start-puppet-agent: Fact file /var/lib/puppet/facts.d/get_directives_details.php was parsed but returned an empty data set

The temporary files are generated correctly in /tmp and I see no SELinux errors. When run manually, the facts scripts produce the right data.

@ubellavance ubellavance changed the title Net facts.d scripts not working when running puppet agent as a servcie facts.d scripts not working when running puppet agent as a servcie Jun 30, 2017
@ubellavance ubellavance changed the title facts.d scripts not working when running puppet agent as a servcie facts.d scripts not working when running puppet agent as a service Jun 30, 2017
@ubellavance
Copy link
Contributor Author

I have a hint. A added debug code to one of the scripts and php returns me invalid argument supplied for foreach()

@ubellavance
Copy link
Contributor Author

@ubellavance
Copy link
Contributor Author

I found it: the zs-client.phar throws PHP notices when run as a daemon because of undefined variables (HOMEDRIVE and HOMEDIR). I finally re-wrote the script in python so that PHP is not a dependency, but I'm not sure if it was necessary. At least now it's working. I did the extensions script, I'll do the directives script as well and then commit.

@ubellavance
Copy link
Contributor Author

Should be fixed by #58

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

1 participant