Skip to content

Instantly share code, notes, and snippets.

Jeremy Baker jbaker10

Block or report user

Report or block jbaker10

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@jbaker10
jbaker10 / show_prompt.ps1
Created Aug 26, 2019
Show prompt in Windows 10
View show_prompt.ps1
Add-Type -AssemblyName PresentationCore,PresentationFramework
$ButtonType = [System.Windows.MessageBoxButton]::YesNo
$MessageboxTitle = “AppGate Upgrade Notice”
$Messageboxbody = “Corp IT needs to upgrade the AppGate client on your device. This upgrade will quit any running sessions of AppGate and may take a few minutes to complete. Are you ready to proceed?”
$MessageIcon = [System.Windows.MessageBoxImage]::Warning
$decision = [System.Windows.MessageBox]::Show($Messageboxbody,$MessageboxTitle,$ButtonType,$messageicon)
$decision
View rollback_workday.py
import json
import time
from httplib2 import Http
from apiclient import discovery, errors
from datadog import initialize, api
from datetime import datetime
from oauth2client.service_account import ServiceAccountCredentials
View GetZoom.ps1
########
## Edit the variables below as necessary
$url = "http://zoom.us/client/latest/ZoomInstallerFull.msi"
$output = "C:\Temp\Zoom.msi"
########
try {
## Kill the process if running
"Trying to quit the application if running"
Stop-Process -Name Zoom* -Force
View enroll_in_airwatch.ps1
$url = "https://storage.googleapis.com/getwsone-com-prod/downloads/AirwatchAgent.msi"
$output = "C:\Temp\AirWatchAgent.msi"
"Checking if temp dir exists, creating if not"
$path = "C:\Temp"
if(!(Test-Path -Path $path)){
"Creating temp directory"
New-Item -ItemType directory -Path $path
}
View promote_to_admin.ps1
"Getting currently logged in user"
$user = '{0}\{1}' -f $env:USERDOMAIN, $env:USERNAME
"Working with user account: " + $user
$user_members = Get-LocalGroupMember -Group Administrators
if ($user_members.Name -like $user) {
$user + " is already a member of the Administrators group"
}
View GetSlack.ps1
$path = "C:\Temp"
if(!(Test-Path -Path $path)){
"Creating C:\Temp"
New-Item -ItemType directory -Path $path
}
$url = "http://slack.com/ssb/download-win64-msi"
$output = "C:\Temp\slack.msi"
View fs_due_date_updater.py
#!/usr/bin/python
'''
A script to automate changing the Due Date of a ticket in FreshService
based on the "Start Date" entered into a Service Request. It will currently
only make the change to tickets that are assigned to the "Onboarding"
group, and those that have been recently updated (within the last hour).
It requires the "requests" library to be installed, which can be installed
by running "sudo easy_install requests".
'''
@jbaker10
jbaker10 / manifest_generator.py
Last active Feb 1, 2018
Using AirWatch API calls, get device information and make Munki manifests from that info
View manifest_generator.py
#!/usr/bin/python
import json
import subprocess
import sys
import os
import plistlib
import requests
@jbaker10
jbaker10 / power_users.sh
Last active Jun 27, 2017
Takes AD admin users and puts them in the Power Users group to perform certain functions
View power_users.sh
#!/bin/bash
#################################################################################
# #
# Script performs the following: #
# 1) Create Power User Group & add AD Standard Users #
# 2) Modify /etc/auth to give powerusers group specified rights #
# 3) Enforce Compliance # #
# AA Accounts are exempted # #
# Version 1.1, 2013-08-12 #
# Version 1.2, 2013-11-19 #
@jbaker10
jbaker10 / elk-zentral.txt
Created May 3, 2017
Setup ELK stack in Zentral
View elk-zentral.txt
## To install Kibana
sudo docker pull sebp/elk:latest
## To run the link on your localhost just to test
docker run --link zentral_elastic_1:elasticsearch -p 127.0.0.1:5601:5601 --net zentral_default kibana
## After this, you should be able to access the Kibana dashboard from 127.0.0.1:5601
## Edit the base.json under conf/start/zentral/base.json
vi ./conf/start/zentral/base.json
You can’t perform that action at this time.