Skip to content

Commit

Permalink
simplified fact generation
Browse files Browse the repository at this point in the history
  • Loading branch information
jordiprats committed Mar 30, 2020
1 parent 19a48ec commit 1e0a6bc
Show file tree
Hide file tree
Showing 13 changed files with 8 additions and 221 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# CHANGELOG

## 0.1.23

* simplified **eypconf** fact generation

## 0.1.22

* added **eypconf_location**
Expand Down
25 changes: 0 additions & 25 deletions lib/facter/eypconf_customer.rb

This file was deleted.

14 changes: 0 additions & 14 deletions lib/facter/eypconf_description.rb

This file was deleted.

26 changes: 0 additions & 26 deletions lib/facter/eypconf_env.rb

This file was deleted.

6 changes: 3 additions & 3 deletions lib/facter/eypconf_generic_id.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Dir.entries("/etc/eypconf/id").select {|f| !File.directory? f}.each do |i|
Dir.entries("/opt/eypconf/id").select {|f| !File.directory? f}.each do |i|

genetic_id = Facter::Util::Resolution.exec("bash -c 'cat /etc/eypconf/id/#{i}'").to_s
genetic_id = Facter::Util::Resolution.exec("bash -c 'cat /opt/eypconf/id/#{i}'").to_s

if i[0]=='.'
fact_name=i[1..-1]
Expand All @@ -15,7 +15,7 @@
end
end

Facter.add("eypconf_#{fact_name}|_uppercase") do
Facter.add("eypconf_#{fact_name}_uppercase") do
setcode do
genetic_id.upcase
end
Expand Down
14 changes: 0 additions & 14 deletions lib/facter/eypconf_location.rb

This file was deleted.

13 changes: 0 additions & 13 deletions lib/facter/eypconf_magic_hash.rb

This file was deleted.

25 changes: 0 additions & 25 deletions lib/facter/eypconf_platformid.rb

This file was deleted.

25 changes: 0 additions & 25 deletions lib/facter/eypconf_servergroup.rb

This file was deleted.

25 changes: 0 additions & 25 deletions lib/facter/eypconf_sg.rb

This file was deleted.

25 changes: 0 additions & 25 deletions lib/facter/eypconf_type.rb

This file was deleted.

25 changes: 0 additions & 25 deletions lib/facter/eypconf_userid.rb

This file was deleted.

2 changes: 1 addition & 1 deletion metadata.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "eyp-eyplib",
"version": "0.1.22",
"version": "0.1.23",
"author": "eyp",
"summary": "Utility functions for puppet modules",
"license": "Apache-2.0",
Expand Down

0 comments on commit 1e0a6bc

Please sign in to comment.