Class: SMCCommands::License

Inherits:
SMCCommandBase show all
Defined in:
lib/setup_oob/command/smc.rb

Overview

Manage the licenses

READ CAREFULLY!! Generating licenses if you haven’t purchased them is illegal! This is here for convenience since the license is derivable from the MAC address, if you have the keys. This allows activating the license in an automated fashion.

I make no claims about the legality of having the key, it probably depends on what country you are in. The key is not distributed with this software. But you can find it if you want.

Constant Summary

Constants inherited from SMCCommandBase

SMCCommandBase::ACTIONS, SMCCommandBase::COMMANDS, SMCCommandBase::DEFAULT_PASSWORD, SMCCommandBase::USER

Instance Attribute Summary

Attributes inherited from CommandBase

#logger

Instance Method Summary collapse

Methods inherited from SMCCommandBase

#basecmd, basecmd, #cmdbytes, #enabled?, #rawcmd, #runraw

Methods inherited from CommandBase

#converged?, #initialize

Constructor Details

This class inherits a constructor from CommandBase

Instance Method Details

#_converged?Boolean

Returns:

  • (Boolean)


260
261
262
# File 'lib/setup_oob/command/smc.rb', line 260

def _converged?
  licensed?
end

#converge!Object



264
265
266
267
268
269
# File 'lib/setup_oob/command/smc.rb', line 264

def converge!
  unless licensed?
    logger.info(' - Setting license')
    set_license
  end
end

#keyObject



256
257
258
# File 'lib/setup_oob/command/smc.rb', line 256

def key
  @data
end