Comments (10)
I'm unfamiliar with puppet on windows so we're going to have to see how far we can come here. Can you share which files do exist on .../var/lib/facter?
from puppet-foreman.
That is the fact "facts" inside this module: foreman/lib/facter/facts.rb
I guess sssd Ruby stuff is not available on a Windows.
Though the fact should not fail, but silently doing nothing. We need to catch that second require there...
from puppet-foreman.
Also it might be not a good idea to name this file "facts.rb", that is a single namespace...
from puppet-foreman.
So... here is what I have on a Windows host:
PS D:\> cd c:\ProgramData\PuppetLabs\puppet\var\lib\facter
PS C:\ProgramData\PuppetLabs\puppet\var\lib\facter> dir
Directory: C:\ProgramData\PuppetLabs\puppet\var\lib\facter
Mode LastWriteTime Length Name
---- ------------- ------ ----
d---- 2/2/2015 8:49 PM util
-a--- 2/2/2015 8:49 PM 920 apt_updates.rb
-a--- 2/2/2015 8:49 PM 597 apt_update_last_success.rb
-a--- 2/2/2015 8:49 PM 212 concat_basedir.rb
-a--- 2/2/2015 8:49 PM 1127 eselect.rb
-a--- 2/2/2015 8:49 PM 4667 facter_dot_d.rb
-a--- 2/2/2015 8:49 PM 1072 facts.rb
-a--- 2/2/2015 8:49 PM 218 gemhome.rb
-a--- 2/2/2015 8:49 PM 236 ip6tables_version.rb
-a--- 2/2/2015 8:49 PM 444 iptables_persistent_version.rb
-a--- 2/2/2015 8:49 PM 234 iptables_version.rb
-a--- 2/2/2015 8:49 PM 2520 oracle_database_homes.rb
-a--- 2/2/2015 8:49 PM 1172 pe_version.rb
-a--- 2/2/2015 8:49 PM 210 portage.rb
-a--- 2/2/2015 8:49 PM 937 puppet_vardir.rb
-a--- 2/2/2015 8:49 PM 104 r10k_environment.rb
-a--- 2/2/2015 8:49 PM 875 root_home.rb
-a--- 2/2/2015 8:49 PM 618 staging_http_get.rb
-a--- 2/2/2015 8:49 PM 251 staging_windir.rb
-a--- 2/2/2015 8:49 PM 232 sudoversion.rb
And here is the util directory:
Mode LastWriteTime Length Name
---- ------------- ------ ----
-a--- 2/2/2015 8:49 PM 432 portage.rb
-a--- 2/2/2015 8:49 PM 660 puppet_settings.rb
-a--- 2/2/2015 8:49 PM 481 sssd.rb
If I look in facts.rb (which, I agree, could do with renaming) I see all the sssd stuff. Originally, I mistakenly thought this was a Puppet bug so I opened FACT-798 and in there it was suggested that a confine based on kernel was needed in the fact.
from puppet-foreman.
My guess is that there's no augeas on windows and that it fails because of it.
from puppet-foreman.
Is plugin sync enabled? the facts.rb is a foreman custom fact. It it looks like its not loading into your lib ruby path correctly.
from puppet-foreman.
Yep, its on.
from puppet-foreman.
Yeah that might actually be the problem that augeas inside sssd.rb can not be loaded:
# facts.rb
begin
require 'facter/util/sssd' # NOTE: augeas failed to load inside
rescue LoadError
# Puppet 2 compatibility, facter/ dir is the load path, not lib/
require 'util/sssd' # NOTE: fails because it's NOT Puppet 2
end
Any good idea how to skip that fact if augeas is not available?
from puppet-foreman.
In util/sssd.rb we could do:
begin require 'augeas' module Facter::Util::Sssd # ... end rescue LoadError => e Facter.debug("Cannot load Augeas library for custom facts: #{e}") end
And in facts.rb (that really needs renaming to not be generic):
if defined? Facter::Util::Sssd Facter.add ..... Facter.add ..... end
from puppet-foreman.
I think the solution @domcleal wrote sounds good. Anyone willing and able to come up with patches?
from puppet-foreman.
Related Issues (20)
- provide a new release that's compatible with puppetlabs/postgresql 8 HOT 3
- foreman_config_entry type does not deal well with array data
- Support apt module v9.x HOT 1
- Puppet Environments/Modules are not updated HOT 4
- puppetlabs/apache: Allow 9.x HOT 1
- Consider using stdlib::ensure_packages HOT 1
- Clicking host hyperlink for puppetclass (under Puppet ENC -> Classes) returns "Field 'class' not recognized for searching!"
- Permissions for foreman::app_root not set correctly HOT 3
- foreman-report_v2 disappeared from master branch ? HOT 2
- Allow customising request header filtering in vhost internal options
- Customisable Yum repository base URL HOT 1
- Allow configuring the priority of the Yum repositories
- Allow customising ProxyAddHeaders
- Feature request: type & provider for "Global Parameters" HOT 2
- Any plans to migrate from camptocamp-systemd to puppet-systemd ? HOT 2
- foreman_config_entry consuming polluted value HOT 4
- Ensuring the ruby module stream on rhel 8 HOT 9
- stale references to some 'globals' variables HOT 2
- Service 'foreman' is started unconditionally HOT 1
- Explicit empty foreman::user_groups parameter does not prevent 'puppet' group addition HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from puppet-foreman.