Skip to content

Instantly share code, notes, and snippets.

View joet3ch's full-sized avatar

Joe Nicosia joet3ch

View GitHub Profile
@joet3ch
joet3ch / keybase.md
Created April 13, 2014 01:00
keybase verify

Keybase proof

I hereby claim:

  • I am joet3ch on github.
  • I am joet3ch (https://keybase.io/joet3ch) on keybase.
  • I have a public key whose fingerprint is F4C6 825F F0EA F9E0 B0F3 023F 88D0 A38F 12D3 6167

To claim this, I am signing this object:

@joet3ch
joet3ch / gist:5a1ac5b895eae5937147
Last active August 29, 2015 14:04
Incident Message - Message Template Example
Status update from *|STATUSPAGENAME|*
Current Status: *|CURRENTSTATUS|*
Started: *|TIMESTART|*
Resolved: *|TIMERESOLVE|*
Affected Infrastructure:
Components: *|AFFECTEDCOMPONENTS|*
Locations: *|AFFECTEDCONTAINERS|*
@joet3ch
joet3ch / gist:bf4d4523c8f22ad50161
Last active August 29, 2015 14:04
Maintenance Reminder - Message Template Example
Scheduled maintenance reminder from *|STATUSPAGENAME|*
Title: *|MAINTENANCETITLE|*
Details: *|MAINTENANCEDETAILS|*
Affected Infrastructure:
Components: *|AFFECTEDCOMPONENTS|*
Locations: *|AFFECTEDCONTAINERS|*
@joet3ch
joet3ch / gist:6157bb9cac0b33bb9bc5
Last active August 29, 2015 14:04
Maintenance Update - Message Template Example
Maintenance update from *|STATUSPAGENAME|*
Title: *|MAINTENANCETITLE|*
Affected Infrastructure:
Components: *|AFFECTEDCOMPONENTS|*
Locations: *|AFFECTEDCONTAINERS|*
Update: *|UPDATEMESSAGE|*
index.php?parameter=1,2,5,3
index.php?parameter[]=1&parameter[]=2&parameter[]=5&parameter[]=3
$array = split(",", $_GET{parameter});
$user = new User();
if (isset($_SERVER['Authorization'])) {
$authorization = $_SERVER['Authorization'];
} elseif (function_exists('apache_request_headers')) {
$headers = apache_request_headers();
if (isset($headers['Authorization'])) {
$authorization = $headers['Authorization'];
}
}
echo $_SERVER['PHP_AUTH_USER'];
#!/usr/bin/perl
use strict;
use Net::Ping;
use DBI;
use Data::Dumper;
use Net::DNS;
# script pings hosts (oh yea)
#!/usr/bin/perl
#
#Fetches a webpage and sends a copy via html email
#
# this is some very old stuff... used it to send my hockey team schedule to the players
#
use strict;
use MIME::Lite;
use LWP::Simple;
#!/usr/bin/perl
my $ifconfig = exec('ifconfig eth0 | grep inet | awk \'{print $2}\'');
$ifconfig =~ /\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}/;
print $ifconfig;
#!/usr/bin/python
''' print all google contacts in xml '''
import gdata.contacts.service
gd_client = gdata.contacts.service.ContactsService()
gd_client.ClientLogin('joe@yomomma.com', 'XXXXXXXXX')
query = gdata.contacts.service.ContactsQuery()