0

I just installed LinuxMint17 Cinanmon in windows virtualbox environment and install ruby and itamae by:

sudo apt-get install ruby
sudo gem i itamae

Then create a recipe.rb:

package 'git'

and run it by sudo itamae local recipe.rb, then I got error:

/var/lib/gems/1.9.1/gems/specinfra-2.44.7/lib/specinfra/command_factory.rb:31:in `const_get': uninitialized constant Specinfra::Command::Linuxmint (NameError)

How can I solve the error?

ironsand
  • 14,329
  • 17
  • 83
  • 176

1 Answers1

0

Specinfra doesn't know about linuxmint, so we must create class for it in recipe.rb.

Specinfra::Command::Linuxmint = Class.new
Specinfra::Command::Linuxmint::Base = Class.new(Specinfra::Command::Ubuntu::Base)
Specinfra::Command::Linuxmint::Base::Ppa = Class.new(Specinfra::Command::Ubuntu::Base::Ppa)
Specinfra::Command::Linuxmint::Base::Service = Class.new(Specinfra::Command::Ubuntu::Base::Service)

Info from this article(in Japanese).

Or use the gem that I changed. I hope this pull request be accepted.

Gemfile

gem 'specinfra', github: 'ironsand/specinfra', branch: 'linuxmint_commands'
gem 'itamae'
ironsand
  • 14,329
  • 17
  • 83
  • 176