Giter VIP home page Giter VIP logo

jamf-snipe-rename's People

Contributors

haircut avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

essd65

jamf-snipe-rename's Issues

Feature request Jamf Asset Tag field

Firstly many thanks for writing these scripts.

I have written a similar shell script in the past which used DeployStudio as the 'source of truth' for computer names and set that as the name in Jamf and like your script fell back to using the computer serial number if no match was found. Obviously having found your script my intention is to this time around use Snipe-IT as the source of truth.

I can see you script will do the same basic requirement of setting the computer name on the computer and in Jamf Pro. I can also see it uses the same method as I used of using the jamf binary setComputerName command.

However in this case I would also like to fill in the 'Asset Tag' field in the computer record in Jamf Pro with the Asset Tag value from Snipe-IT. Clearly this is a duplication since the intent of this script is to use that value as the computer name and Jamf computer record name but this field is specifically for the Asset Tag name and filling this in also means that if for some reason the someone manages to rename the computer that value is still around in Jamf.

Screenshot 2021-09-24 at 16 55 45

It turns out that the Jamf binary also has the ability to set the Jamf computer record asset tag value.

jamf recon -assetTag $asset

Whilst it is therefore a trivial change to your script for myself to add you may want to consider this.

Note: An alternative approach might be to use Jamf Pro's own API to directly write to the field and not use the Jamf binary.

Similarly receiving the TOKEN_SALT and TOKEN_PASSPHRASE as Jamf command arguments like the Token API Key would also be beneficial.

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.