plus3it / join-domain-formula

Salt formula to join systems to an Active Directory domain
Apache License 2.0
13 stars 19 forks source link

[Enhancement] Ensure that AD ComputerObject Is Regularly Refreshed #201

Closed ferricoxide closed 1 year ago

ferricoxide commented 1 year ago

Vendor documentation recommends that AD-joined systems be configured to regularly update their computerObject information in active directory. Need to add either a systemd unit file – configured to run at each system boot – or a regularly-executed cron job to handle the task.

Given that domain-joined systems are typically not rebooted as frequently as the desired refresh interval (less than 30 days), adding an /etc/cron.{daily,weekly,monthly} script with contents similar to:

source /etc/os-release
/usr/sbin/adcli update \
  --os-name="${NAME}" \
  --os-version="${VERSION}" \
  --os-service-pack="${VERSION_ID}"

Would be the preferred method for ensuring adequately-frequent object-refreshing.