def execute(self, opts):
    if (opts.send_password is not None):
        path = [CB_BIN_PATH, os.environ['PATH']]
        if (os.name == 'posix'):
            os.environ['PATH'] = ':'.join(path)
        else:
            os.environ['PATH'] = ';'.join(path)
        cookiefile = os.path.join(opts.config_path, 'couchbase-server.babysitter.cookie')
        if (not os.path.isfile(cookiefile)):
            _exit_if_errors(['The node is down'])
        cookie = _exit_on_file_read_failure(cookiefile, 'Insufficient privileges to send master password - Please execute this command as a operating system user who has file system read permission on the Couchbase Server  configuration').rstrip()
        nodefile = os.path.join(opts.config_path, 'couchbase-server.babysitter.node')
        node = _exit_on_file_read_failure(nodefile).rstrip()
        self.prompt_for_master_pwd(node, cookie, opts.send_password, opts.config_path)
    else:
        _exit_if_errors(['No parameters set'])
def execute(self, opts):
    if (opts.send_password is not None):
        path = [CB_BIN_PATH, os.environ['PATH']]
        if (os.name == 'posix'):
            os.environ['PATH'] = ':'.join(path)
        else:
            os.environ['PATH'] = ';'.join(path)
        cookiefile = os.path.join(opts.config_path, 'couchbase-server.babysitter.cookie')
        if (not os.path.isfile(cookiefile)):
            _exit_if_errors(['The node is down'])
        cookie = _exit_on_file_read_failure(cookiefile, 'Insufficient privileges to send master password - Please execute this command as a operating system user who has file system read permission on the Couchbase Server  configuration').rstrip()
        nodefile = os.path.join(opts.config_path, 'couchbase-server.babysitter.node')
        node = _exit_on_file_read_failure(nodefile).rstrip()
        self.prompt_for_master_pwd(node, cookie, opts.send_password, opts.config_path)
    else:
        _exit_if_errors(['No parameters set'])