In a customized modules on Puppet I have and I want to let the module do something whether or not the file “fqdn-of-server” exist on the Puppet Master. Googling did get me a file_exists.rb function: and this does work when put in something like: in my manifest init.pp (of course $fqdn is a facter). The problem is that it works
Tag: ruby
Missing library while installing ruby-filemagic gem on Linux
I needed gem ruby-filemagic for some requirements in my project. While running bundle install its giving me this error Please help me with this problem. Answer sudo apt-get install libmagic-dev did it for me
ruby Array.inspect vs. Array[element].to_s
I’m working with an array, which we’ll call books, of complex objects, which we’ll call Book. The problem is when I call puts “#{books.inspect}”, ruby outputs a stream of binary (unreadable utf8 characters). However, when I call puts #{books[0].to_str}”, I get a brief, pretty output that describes the book in question. Not sure if it is relevant, but Book is
Gem Command not found
I have installed gem on Ubuntu 10.10 32 bit with But when I try to run I get the error of the command not being found. I installed gem, is there any reason it is saying it can’t find the command? These files were install by gem package http://pastie.org/3483416 Answer Are you wanting ruby gems? If so, you need to
Cannot install ruby version on redhat
I have the following problem and whatever I try, nothing helps. I hope someone could help me with this. I have a redhat server and I’m trying to install redmine on it. Redmine needs Ruby >= 1.8.7 to run so I installed it and when I execute ruby -v in the console it says I have version 1.8.7 (so that’s
Erroneous “Insecure world writable dir foo in PATH” when running ruby script
When I run a ruby script, it gives me this: This message is erroneous, because /usr/software is mounted read-only: And I can verify this: I believe my mount point has the correct permissions: So two questions: Could this legitimately be considered a bug in Ruby? How do I shut this up? Is there a way to disable only this specific