Skip to content

Instantly share code, notes, and snippets.

richard-scott / sane_defaults.rb
Created June 9, 2022 22:11 — forked from irvingpop/sane_defaults.rb
Vagrant: Irving's sane defaults for Virtualbox with better performance
View sane_defaults.rb
# replaces this file /opt/vagrant/embedded/gems/gems/vagrant-1.7.4/plugins/providers/virtualbox/action/sane_defaults.rb
# NOTE: if using a different Vagrant version, adjust the version field accordingly
# NOTE2: only the sections with the IRVING comment have been changed from the default
require "log4r"
module VagrantPlugins
module ProviderVirtualBox
module Action
class SaneDefaults
richard-scott /
Created April 21, 2022 13:10 — forked from jesslilly/
Deluxe Cron Job Wrapper

Cron Job Wrapper Wish List

I want a script that will give me:

  1. Logging
  2. Log purging!
  3. Email errors!
  4. Prevent duplicate processes! (flock)
  5. Source an environment file!
  6. Anything else?
View AlmaLinux Kickstart Config
repo --name="Minimal" --baseurl=file:///run/install/sources/mount-0000-cdrom/Minimal
View Add DS_Store into .gitignore for the sub

If .DS_Store was never added to your git repository, simply add it to your .gitignore file.

If you don't have one, create a file called


In your the root directory of your app and simply write

richard-scott /
Created May 17, 2021 14:38 — forked from drorata/
Minimal example of sending a JSON over email
import json
# Import smtplib for the actual sending function
import smtplib
# Import the email modules we'll need
from email.mime.text import MIMEText
from email.mime.multipart import MIMEMultipart
from datetime import datetime
def send_email(data):
richard-scott /
Created June 25, 2020 14:58 — forked from artkrz/
Remove measurements from HASS InfluxDB
measurements=($(influx --host $host --execute 'show measurements' --database=$db | grep "$1"))
if (( ${#measurements[@]} ))
richard-scott /
Created March 30, 2020 15:14 — forked from darahayes/
KMS Encrypt and Decrypt filters in Ansible

KMS Encrypt and Decrypt Filters for Ansible

This Gist shows how you can encrypt/decrypt variables with KMS during your Ansible playbook execution. While google searching I couldn't find anything useful on the subject.

Let's say your project has a folder of playbooks called plays.

In that folder, create a folder called filter_plugins and insert (included in this gist)

richard-scott /
Created October 15, 2019 11:06 — forked from mgoodness/
AWS ELB-related annotations for Kubernetes Services (as of v1.12.0)

AWS Service annotations

  • (in minutes)
  • (true|false)
  • (comma-separated list of key=value)
  • (http|https|ssl|tcp)
  • (true|false)
richard-scott /
Created October 10, 2019 11:44 — forked from p3t3r67x0/
Some list of openssl commands for check and verify your keys



Install the OpenSSL on Debian based systems

sudo apt-get install openssl
richard-scott / GetAllWifiPasswords.ps1
Created October 4, 2019 16:05 — forked from Saturate/GetAllWifiPasswords.ps1
PowerShell Wifi Script
View GetAllWifiPasswords.ps1
# Run this script as an Admin user and get a list of all WiFi passwords.
$listProfiles = netsh wlan show profiles | Select-String -Pattern "All User Profile" | %{ ($_ -split ":")[-1].Trim() };
$listProfiles | foreach {
$profileInfo = netsh wlan show profiles name=$_ key="clear";
$SSID = $profileInfo | Select-String -Pattern "SSID Name" | %{ ($_ -split ":")[-1].Trim() };
$Key = $profileInfo | Select-String -Pattern "Key Content" | %{ ($_ -split ":")[-1].Trim() };
WifiProfileName = $SSID;
Password = $Key