Skip to content

Instantly share code, notes, and snippets.

View huevos-y-bacon's full-sized avatar

Huevos y Bacon huevos-y-bacon

View GitHub Profile
@huevos-y-bacon
huevos-y-bacon / Brewfile
Last active August 17, 2022 21:50
MacOS: bulk install apps via Homebrew, including App Store apps. Edit the various Brewfiles and run `brew-bundle.sh`
# BASE
tap "homebrew/bundle"
tap "homebrew/cask"
tap "homebrew/core"
# BASE Apps
cask "joplin"
cask "bettertouchtool"
cask "visual-studio-code"
cask "bitwarden"
@mlapida
mlapida / EC2-Tag-Assets-Lambda.py
Last active January 17, 2024 08:10
A lambda function that will copy EC2 tags to all related Volumes and Network Interfaces. A full writeup can be found on my site https://empty.coffee/tagging-and-snapshotting-with-lambda/ - Thank you to the community for keeping this updated!
from __future__ import print_function
import json
import boto3
import logging
#setup simple logging for INFO
logger = logging.getLogger()
logger.setLevel(logging.ERROR)
@sebsto
sebsto / gist:468670c7c0d5feeade69
Created March 20, 2015 07:53
AWS CLI : discover your service limits from the command line
aws support describe-trusted-advisor-check-result --check-id eW7HH0l7J9 --query 'result.sort_by(flaggedResources[?status!="ok"],&metadata[2])[].metadata' --output table --region us-east-1
@winhamwr
winhamwr / ipsec-monitor.sh
Created December 10, 2013 19:55
Script to check the status of ipsec tunnels and refresh them if they're down. This should be run from cron every minute. To add monitoring on a tunnel, add a commented-out `monitor` line with the IP and port to use for establishing connection status. eg. `#monitor 172.17.105.80 9898` Adapted from a script posted by user "c b" on Strongswan [issu…
#!/bin/bash
function main()
{
monitor_from_file $*
}
function monitor_vpn_ip_port()
{
local CONN_NAME=$1
@timnew
timnew / Rename.ps1
Last active March 15, 2024 13:49
Script to Rename Computer without Reboot
$ComputerName = "New Name"
Remove-ItemProperty -path "HKLM:\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters" -name "Hostname"
Remove-ItemProperty -path "HKLM:\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters" -name "NV Hostname"
Set-ItemProperty -path "HKLM:\SYSTEM\CurrentControlSet\Control\Computername\Computername" -name "Computername" -value $ComputerName
Set-ItemProperty -path "HKLM:\SYSTEM\CurrentControlSet\Control\Computername\ActiveComputername" -name "Computername" -value $ComputerName
Set-ItemProperty -path "HKLM:\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters" -name "Hostname" -value $ComputerName
Set-ItemProperty -path "HKLM:\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters" -name "NV Hostname" -value $ComputerName
Set-ItemProperty -path "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon" -name "AltDefaultDomainName" -value $ComputerName