def METHOD_NAME(machine_id=None, group=None):
    """Lock a machine. If no group is specified, the local default group
       will be used. If no machine-id is specified, the local machine
       will be locked.
    machine_id
        The machine-id is a network wide, unique ID. Per default the
        ID from /etc/machine-id is used.
    group
        Group name
    CLI Example:
    .. code-block:: bash
        salt microos rebootmgr lock group=group1
    """
    cmd = ["rebootmgrctl", "lock"]
    if group:
        cmd.extend(["--group", group])
    if machine_id:
        cmd.append(machine_id)
    return _cmd(cmd)