- Open the Terminal Application
- Type in
sudo -i
and type in your Mac Administrator account password.sudo
gives you root level or administrator level privileges.
dsconfigad -show
#!/bin/bash | |
# NOTE: this is an OSX launchd wrapper shell script for Tomcat (to be placed in $CATALINA_HOME/bin) | |
CATALINA_HOME=/Users/username/tomcat | |
function shutdown() { | |
date | |
echo "Shutting down Tomcat" | |
$CATALINA_HOME/bin/catalina.sh stop |
sudo -i
and type in your Mac Administrator account password. sudo
gives you root level or administrator level privileges.dsconfigad -show
This is a bash script that will automatically turn your wifi off if you connect your computer to an ethernet connection and turn wifi back on when you unplug your ethernet cable/adapter. If you decide to turn wifi on for whatever reason, it will remember that choice. This was improvised from this mac hint to work with Yosemite, and without hard-coding the adapter names. It's supposed to support growl, but I didn't check that part. I did, however, add OSX notification center support. Feel free to fork and fix any issues you encounter.
Most the credit for these changes go to Dave Holland and Albert Bori
#!/usr/bin/env python | |
"""https://twitter.com/krispayne/status/859833552078225408: | |
@shea_craig is possible with python-jss to generate a list of IP addresses for | |
computers in the JSS? | |
""" | |
from operator import itemgetter | |
# This example uses python-jss 2.0.0+ |
#!/usr/bin/env ruby | |
require 'uri' | |
require 'json' | |
require 'net/https' | |
require 'time' | |
require 'cgi' | |
require 'csv' | |
# You need a Spotify API app to have a client ID and client secret. Create | |
# one at https://developer.spotify.com/my-applications/#!/applications/create |
#!/usr/bin/python3.4 | |
""" | |
Custom inventory script for Ansible populated by the JSS | |
""" | |
from os.path import dirname, realpath, join | |
from urllib.parse import quote | |
import argparse | |
import json | |
import configparser |
#!/usr/bin/env python | |
import argparse | |
import json | |
from ipalib import api | |
def initialize(): | |
''' | |
This function initializes the FreeIPA/IPA API. This function requires |
[devyn@ipa ~]$ ipa help commands
automember-add Add an automember rule.
automember-add-condition Add conditions to an automember rule.
automember-default-group-remove Remove default (fallback) group for all unmatched entries.
automember-default-group-set Set default (fallback) group for all unmatched entries.
automember-default-group-show Display information about the default (fallback) automember groups.
automember-del Delete an automember rule.
automember-find Search for automember rules.
automember-mod Modify an automember rule.
#!/usr/bin/python | |
import sys, os | |
import urllib, urllib2 | |
import base64 | |
import json | |
import requests | |
import xml.etree.ElementTree as ET | |
def requests_xml(jss_user, jss_pass, jss_url, category): |