Coder Social home page Coder Social logo

bordwalk2000 / computerdescription Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 1.0 103 KB

This module retrieves information from Windows computers and replaces its AD object's description with the data obtained from the module.

License: MIT License

PowerShell 100.00%

computerdescription's Introduction

ComputerDescription PowerShell Module

This module retrieves information from Windows computers, creates a description string, and compares it to the existing description in Active Directory. If there are discrepancies, the script will prompt you to confirm any changes before updating the Active Directory object description field.

The AD Computer description will be stored in the following format.

Primary User | Service Tag [| Asset Tag] | 'Deployed' OS Installed Date (YYYY-MM-DD)

๐Ÿš€ Getting Started

The following is the bare minimum required to successfully run the Update-ADComputerDescription function and update an AD object's description.

Update-ADComputerDescription -ComputerName PC1

Example AD computer description from the previous command

John Smith | ABCD123 | Deployed 2024-12-31

To store AssetTag information and avoid being prompted to confirm changes, run the following command.

Update-ADComputerDescription -OUPath 'OU=Computers,DC=Example,DC=com' -AssetTagSupport -AssetTagRegex '^[C]\d{5}$' -Confirm:$false 

Example AD computer description from the previous command

John Smith | ABCD123 | C12345 | Deployed 2024-12-31

I suggest starting by targeting a few machines or an Organizational Unit (OU) with a limited number of computer objects. This approach allows you to verify that everything is working correctly. If you encounter any issues, you can use the following switches to gather more detailed information about the process.

Update-ADComputerDescription -ComputerName PC1, PC2, PC3 -Verbose -Debug

โ— Warning

After you confirm that you want to update the AD computer's description this will overwrite what was previously stored there and you can no longer get it back. I highly recommend creating a backup of of your AD computer's description field before running the script.

Get-ADComputer -Filter * -Properties Description -SearchBase "OU=Computers,DC=Example,DC=com" | Select Name, Description | Export-Csv "AD Computer Descriptions.csv" 

๐Ÿ’ฟ Installation

This module is hosted on the PowerShell gallery. It can be installed using the following command.

Install-Module -Name ComputerDescription

๐Ÿ’ฝ Building Module from Scratch

This module is currently being built with the gaelcolas's Sampler module using the build.ps1 file.

computerdescription's People

Contributors

bordwalk2000 avatar

Watchers

 avatar  avatar

Forkers

chefboyrjeff

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.