Revision 1fa6fcba lib/rapi/client.py

b/lib/rapi/client.py
1057 1057
                             ("/%s/instances/%s/shutdown" %
1058 1058
                              (GANETI_RAPI_VERSION, instance)), query, body)
1059 1059

  
1060
  def StartupInstance(self, instance, dry_run=False, no_remember=False):
1060
  def StartupInstance(self, instance, dry_run=False, no_remember=False,
1061
                      reason=None):
1061 1062
    """Starts up an instance.
1062 1063

  
1063 1064
    @type instance: str
......
1066 1067
    @param dry_run: whether to perform a dry run
1067 1068
    @type no_remember: bool
1068 1069
    @param no_remember: if true, will not record the state change
1070
    @type reason: string
1071
    @param reason: the reason for the startup
1069 1072
    @rtype: string
1070 1073
    @return: job id
1071 1074

  
......
1073 1076
    query = []
1074 1077
    _AppendDryRunIf(query, dry_run)
1075 1078
    _AppendIf(query, no_remember, ("no_remember", 1))
1079
    _AppendIf(query, reason, ("reason", reason))
1076 1080

  
1077 1081
    return self._SendRequest(HTTP_PUT,
1078 1082
                             ("/%s/instances/%s/startup" %

Also available in: Unified diff