Monday, August 26, 2013

Spiceworks: Generate Ticket for upgrade notice

This is quick write up of experience implementing How-To: How to automatically create a ticket on Spiceworks upgrade by Vasily Ignatov.

Objective: Generate a ticket in Spiceworks when upgrade is released.  Provides upgrade history and ensures completed in timely manner.

  1. Navigated to following link and save the script:
  2. Create a storage directory 
    • Create a directory for downloaded Spiceworks installers and define the path_to_store_exe variable in the script. Grant write access to this folder for account, which will run the script.
    • We used \\server\shared\IT\Software\Spiceworks\Installers
  3. Fill in other variables in the script
    • All settings to fill in bounded with lines "=== Define your parameters ==="
      • $smtp_server = "smtp.domain.com"
      • $smtp_server_port = "25"
      • $SSL_is_used = $false
      • $ticket_creator_email = "admin@domain.com"
      • $ticket_creator_email_pass = ""
      • $helpdesk_email = "helpdesk@domain.com"
      • $helpdesk_url = "http://helpdesk.domain.com:port"
      • $path_to_store_exe = "D:\SW-Install\"
      • $LANG = "EN"
  4. Schedule a task Schedule a task to run the script every day at 09 AM or whenever you want.
    • Start > Run > Taskschd.msc
    • Task Scheduler Library > Action > Create Task
    • General
      • Name: Spiceworks Ticket Upgrade
      • Description: Run PS script to check for Spiceworks updates.  Generate ticket as needed.
      • Security Options: Run whether user is logged in or not
    • Triggers
      • New > On a schedule
      • Settings 
        • Define when you want to run
      • Advanced Settings
        • Ensure Enabled is checked
        • I like to set stop for tasks if they run more then an hr
    • Actions
      • New > Start a program
      • Settings:
        • Program/script: powershell
        • Add Arguments: -file [path to script enclose in "" if spaces in path]
    • Conditions
      • Adjust as needed
    • Settings
      • Adjust as needed
    • History
      • Log to verify running
    • Upon saving will be prompted for user password
That is it.  Now in the folder you have defined installers will be downloaded being named according to versions.  Also in the folder will be the log file (check_sw_ver.log) and the md5sums.

Download script, readme and task scheduler template at:
https://docs.google.com/file/d/0B1fwreWrAZiobmlXT1Y1ZGpCSEE/edit?usp=sharing


No comments:

Post a Comment