Class: Jamf::ComputerGroup
- Includes:
- MDM, MacOSManagedUpdates, MacOSRedeployMgmtFramework
- Defined in:
- lib/jamf/api/classic/api_objects/computer_group.rb
Overview
A computer group in the JSS
See also the parent class Jamf::Group
Constant Summary collapse
- RSRC_BASE =
The base for REST resources of this class
'computergroups'
- RSRC_LIST_KEY =
the hash key used for the JSON list output of all objects in the JSS
:computer_groups
- RSRC_OBJECT_KEY =
The hash key used for the JSON object output. It’s also used in various error messages
:computer_group
- MEMBER_CLASS =
this allows the parent Group class to do things right
Jamf::Computer
- ADD_MEMBERS_ELEMENT =
the XML element for immediate member additions via PUT
'computer_additions'.freeze
- REMOVE_MEMBERS_ELEMENT =
the XML element for immediate member removals via PUT
'computer_deletions'.freeze
- OBJECT_HISTORY_OBJECT_TYPE =
the object type for this object in the object history table. See APIObject#add_object_history_entry
7
- MDM_COMMAND_TARGET =
what kind of devices are these WRT MDM
:computergroups
Instance Attribute Summary collapse
-
#criteria ⇒ Jamf::Criteriable::Criteria
included
from Criteriable
The criteria for the instance into which we’re mixed.
-
#need_to_update ⇒ Boolean
included
from Updatable
readonly
Do we have unsaved changes?.
Instance Method Summary collapse
-
#blank_push ⇒ void
(also: #send_blank_push, #noop)
included
from MDM
Send a blank push to this object.
-
#clear_passcode ⇒ Object
included
from MDM
Send an clear_passcode command to this object.
-
#clear_restrictions_password ⇒ Object
included
from MDM
Send an clear_restrictions_password command to this object.
-
#delete_user(user) ⇒ Object
included
from MDM
Send a delete_user command to this computer or group.
-
#device_lock(passcode_or_message = '') ⇒ Object
(also: #lock, #lock_device)
included
from MDM
Send a dev lock to this object.
-
#device_name(name) ⇒ Object
(also: #set_name, #set_device_name)
included
from MDM
Send a device_name command to this object.
-
#disable_app_analytics ⇒ Object
included
from MDM
Send a disable_app_analytics command to this object.
-
#disable_data_roaming ⇒ Object
included
from MDM
Send a disable_data_roaming command to this object.
-
#disable_diagnostic_submission ⇒ Object
included
from MDM
Send a disable_diagnostic_submission command to this object.
-
#disable_lost_mode ⇒ Object
included
from MDM
Send a disable_lost_mode command to this object.
-
#disable_remote_desktop ⇒ Object
included
from MDM
Send a disable_remote_desktop command to this computer or group.
-
#disable_voice_roaming ⇒ Object
included
from MDM
Send a disable_voice_roaming command to this object.
-
#enable_app_analytics ⇒ Object
included
from MDM
Send an enable_app_analytics command to this object.
-
#enable_data_roaming ⇒ Object
included
from MDM
Send an enable_data_roaming command to this object.
-
#enable_diagnostic_submission ⇒ Object
included
from MDM
Send an enable_diagnostic_submission command to this object.
-
#enable_lost_mode(message: nil, phone: nil, footnote: nil, enforce_lost_mode: false, play_sound: false) ⇒ Object
included
from MDM
Send a enable_lost_mode command to one or more targets.
-
#enable_remote_desktop ⇒ Object
included
from MDM
Send an enable_remote_desktop command to this computer or group.
-
#enable_voice_roaming ⇒ Object
included
from MDM
Send an enable_voice_roaming command to this object.
-
#erase_device(passcode = '', preserve_data_plan: false) ⇒ Object
(also: #wipe_device, #wipe_computer, #wipe, #erase)
included
from MDM
Send an erase device command to this object.
-
#flush_mdm_commands(status) ⇒ void
included
from MDM
flush pending and/or failed MDM commands for this object.
-
#member_mac_addresses ⇒ Array<String>
Return an array of the mac_addrs of members in this group.
-
#member_serial_numbers ⇒ Array<String>
The serial numbers of members in this group.
-
#passcode_lock_grace_period(secs) ⇒ Object
included
from MDM
Send a passcode_lock_grace_period command to this object.
-
#play_lost_mode_sound ⇒ Object
included
from MDM
Send a play_lost_mode_sound command to this object.
-
#redeploy_mgmt_framework ⇒ Object
included
from MacOSRedeployMgmtFramework
Send a managed update command to an instance of Computer or ComputerGroup.
-
#restart_device ⇒ Object
(also: #restart)
included
from MDM
Send a restart_device command to this object.
-
#send_managed_os_update(updateAction:, maxDeferrals: nil, version: nil, skipVersionVerification: false, applyMajorUpdate: false, forceRestart: false) ⇒ Object
included
from MacOSManagedUpdates
Send a managed update command to an instance of Computer or ComputerGroup.
-
#shut_down_device ⇒ Object
(also: #shutdown_device, #shut_down, #shutdown)
included
from MDM
Send a shut_down_device command to this object.
-
#unlock_user_account(user) ⇒ Object
included
from MDM
Send an unlock_user_account command to this computer or group.
-
#unmanage_device ⇒ Object
(also: #remove_mdm_profile)
included
from MDM
Send an unmanage device command to this object.
-
#update_inventory ⇒ Object
(also: #recon)
included
from MDM
Send an update_inventory command to this object.
-
#wallpaper(wallpaper_setting: nil, wallpaper_content: nil, wallpaper_id: nil) ⇒ Object
(also: #set_wallpaper)
included
from MDM
Send a wallpaper command to this object.
Constructor Details
This class inherits a constructor from Jamf::Group
Instance Attribute Details
#criteria ⇒ Jamf::Criteriable::Criteria Originally defined in module Criteriable
Returns the criteria for the instance into which we’re mixed.
#need_to_update ⇒ Boolean (readonly) Originally defined in module Updatable
Returns do we have unsaved changes?.
Instance Method Details
#blank_push ⇒ void Also known as: send_blank_push, noop Originally defined in module MDM
This method returns an undefined value.
Send a blank push to this object
#clear_passcode ⇒ Object Originally defined in module MDM
Send an clear_passcode command to this object
#clear_restrictions_password ⇒ Object Originally defined in module MDM
Send an clear_restrictions_password command to this object
#delete_user(user) ⇒ Object Originally defined in module MDM
Send a delete_user command to this computer or group
#device_lock(passcode_or_message = '') ⇒ Object Also known as: lock, lock_device Originally defined in module MDM
Send a dev lock to this object
#device_name(name) ⇒ Object Also known as: set_name, set_device_name Originally defined in module MDM
Send a device_name command to this object
#disable_app_analytics ⇒ Object Originally defined in module MDM
Send a disable_app_analytics command to this object
#disable_data_roaming ⇒ Object Originally defined in module MDM
Send a disable_data_roaming command to this object
#disable_diagnostic_submission ⇒ Object Originally defined in module MDM
Send a disable_diagnostic_submission command to this object
#disable_lost_mode ⇒ Object Originally defined in module MDM
Send a disable_lost_mode command to this object
#disable_remote_desktop ⇒ Object Originally defined in module MDM
Send a disable_remote_desktop command to this computer or group
#disable_voice_roaming ⇒ Object Originally defined in module MDM
Send a disable_voice_roaming command to this object
#enable_app_analytics ⇒ Object Originally defined in module MDM
Send an enable_app_analytics command to this object
#enable_data_roaming ⇒ Object Originally defined in module MDM
Send an enable_data_roaming command to this object
#enable_diagnostic_submission ⇒ Object Originally defined in module MDM
Send an enable_diagnostic_submission command to this object
#enable_lost_mode(message: nil, phone: nil, footnote: nil, enforce_lost_mode: false, play_sound: false) ⇒ Object Originally defined in module MDM
Send a enable_lost_mode command to one or more targets
Either or both of message and phone number must be provided
#enable_remote_desktop ⇒ Object Originally defined in module MDM
Send an enable_remote_desktop command to this computer or group
#enable_voice_roaming ⇒ Object Originally defined in module MDM
Send an enable_voice_roaming command to this object
#erase_device(passcode = '', preserve_data_plan: false) ⇒ Object Also known as: wipe_device, wipe_computer, wipe, erase Originally defined in module MDM
Send an erase device command to this object
#flush_mdm_commands(status) ⇒ void Originally defined in module MDM
This method returns an undefined value.
flush pending and/or failed MDM commands for this object
#member_mac_addresses ⇒ Array<String>
Return an array of the mac_addrs of members in this group
96 97 98 |
# File 'lib/jamf/api/classic/api_objects/computer_group.rb', line 96 def member_mac_addresses @members.map { |m| m[:mac_address] } + @members.map { |m| m[:alt_mac_address] } end |
#member_serial_numbers ⇒ Array<String>
The serial numbers of members in this group
87 88 89 |
# File 'lib/jamf/api/classic/api_objects/computer_group.rb', line 87 def member_serial_numbers @members.map { |m| m[:serial_number] } end |
#passcode_lock_grace_period(secs) ⇒ Object Originally defined in module MDM
Send a passcode_lock_grace_period command to this object
#play_lost_mode_sound ⇒ Object Originally defined in module MDM
Send a play_lost_mode_sound command to this object
#redeploy_mgmt_framework ⇒ Object Originally defined in module MacOSRedeployMgmtFramework
Send a managed update command to an instance of Computer or ComputerGroup. This just calls the class method of the same name.
#restart_device ⇒ Object Also known as: restart Originally defined in module MDM
Send a restart_device command to this object
#send_managed_os_update(updateAction:, maxDeferrals: nil, version: nil, skipVersionVerification: false, applyMajorUpdate: false, forceRestart: false) ⇒ Object Originally defined in module MacOSManagedUpdates
Send a managed update command to an instance of Computer or ComputerGroup. This just calls the class method of the same name.
#shut_down_device ⇒ Object Also known as: shutdown_device, shut_down, shutdown Originally defined in module MDM
Send a shut_down_device command to this object
#unlock_user_account(user) ⇒ Object Originally defined in module MDM
Send an unlock_user_account command to this computer or group
#unmanage_device ⇒ Object Also known as: remove_mdm_profile Originally defined in module MDM
Send an unmanage device command to this object
NOTE: when used with computers, the mdm profile will probably be re-installed immediately unless the computer is also no longer managed by Jamf Pro itself. To fully unmanage a computer, use the Computer#make_unmanaged instance method.