Odyssey
Public Member Functions | Static Public Attributes | List of all members
cli.base.HostingCommand Class Reference
Inheritance diagram for cli.base.HostingCommand:
cli.certificates.CertificateCommand cli.certificates.UploadCertificateCommand cli.cumanage.CUManageCommand cli.deploy.DeployCommand cli.ecr.CatalogCommand cli.ecr.ECRCommand cli.ecr.ListImagesCommand cli.ecr.PushCommand cli.ecr.RemoveTagCommand cli.logs.LogsCommand cli.sched.ReloadCommand cli.sched.SchedCommand cli.stack.CreateCommand cli.stack.GetEnvCommand cli.stack.ListCommand cli.stack.MaintCommand cli.stack.MonitorCommand cli.stack.RemoveCommand cli.stack.ScaleCommand cli.stack.SetEnvCommand cli.stack.SetStackStateCommand cli.stack.ShowCommand cli.stack.StackCommand cli.stack.UpgradeCommand

Public Member Functions

def add_stack_argument (self, *args, env=DEFAULT_STACK_ENV, help=None, metavar='STACK_NAME', **kwargs)
 
def check_requirements (self, stack)
 

Static Public Attributes

 allowed_states = set()
 
string min_version = "0"
 
 max_version = VERSION
 

Detailed Description

Definition at line 48 of file base.py.

Member Function Documentation

◆ check_requirements()

def cli.base.HostingCommand.check_requirements (   self,
  stack 
)
Used to assert a stack is compatible and in a viable state. 

Definition at line 65 of file base.py.

65  def check_requirements(self, stack):
66  """ Used to assert a stack is compatible and in a viable state. """
67  ver = stack.stack_version
68  if not (self.min_version <= ver <= self.max_version):
69  raise SystemExit("Incompatible version: %s" % ver)
70  if stack.state not in self.allowed_states:
71  raise SystemExit("Improper stack state: %s" % stack.state)

The documentation for this class was generated from the following file: