Skip to content

Instantly share code, notes, and snippets.

View dmitrievav's full-sized avatar

Alexey dmitrievav

View GitHub Profile
@dwalters-zz
dwalters-zz / linksys-config.rb
Created June 14, 2012 16:42
Script to encrypt/decrypt config backups of a Linksys EA3500 V1 router (on stock firmware.)
#!/usr/bin/env ruby
#
# Script to decrypt (and reencrypt) Linksys EA3500 v1.0 configuration file backups, e.g.,
# Linksys_EA3500V1_v1.0.30.126544.cfg . The result of decryption is a plain text nvram dump that
# can be edited, re-encrypted, and uploaded back into the router.
#
# Depends on Ruby 1.9 and an openssl command line binary.
require 'optparse'
require 'tempfile'
@fujimogn
fujimogn / homebrew.mxcl.pdnsd.plist
Created August 20, 2012 06:01
Installing pdnsd from Homebrew

Installing pdnsd from homebrew as root user.

$ brew install pdnsd

$ sudo chown -R nobody /usr/local/var/cache/pdnsd

$ curl -L http://goo.gl/kMlyQ -o pdnsd.conf
$ mv pdnsd.conf /usr/local/etc
$ sudo chown root /usr/local/etc/pdnsd.conf
@KartikTalwar
KartikTalwar / Documentation.md
Last active June 25, 2024 10:55
Rsync over SSH - (40MB/s over 1GB NICs)

The fastest remote directory rsync over ssh archival I can muster (40MB/s over 1gb NICs)

This creates an archive that does the following:

rsync (Everyone seems to like -z, but it is much slower for me)

  • a: archive mode - rescursive, preserves owner, preserves permissions, preserves modification times, preserves group, copies symlinks as symlinks, preserves device files.
  • H: preserves hard-links
  • A: preserves ACLs
@SavvyGuard
SavvyGuard / botos3upload.py
Last active February 8, 2023 14:56
Use boto to upload directory into s3
import boto
import boto.s3
import os.path
import sys
# Fill these in - you get them when you sign up for S3
AWS_ACCESS_KEY_ID = ''
AWS_ACCESS_KEY_SECRET = ''
# Fill in info on data to upload
@soarez
soarez / ca.md
Last active June 19, 2024 19:32
How to setup your own CA with OpenSSL

How to setup your own CA with OpenSSL

For educational reasons I've decided to create my own CA. Here is what I learned.

First things first

Lets get some context first.

@Valiev
Valiev / check.sh
Created December 30, 2014 13:11
pre-commit hook for Chef configuration repo
#!/usr/bin/env sh
set -e
# set -x
set -o pipefail
die() { echo "$@" 1>&2 ; exit 1; }
# ========================================================================
# Initialization
@pcn
pcn / Comparison.adoc
Last active July 29, 2020 18:38
Going to saltstack from chef as a user

About me

I’m an intermediate/advanced chef user. My main usage has been as a client of the services that chef provides, and not operating the server. My comfort zone is that I am very happy to write and hack on fairly complicated chef cookbooks, LWRPs, and chef-solo work, but I don’t work much with the chef server - I’ve opted to use the hosted service in the past, and very much enjoyed the service.

Why Saltstack?

I’m interested in saltstack. When I first started working with chef in 2011, saltstack was very new, so I learned chef, as the more mature option (though it was still fairly new). Now salt is in a fairly mature phase where it seems to be able to handle the same classes of installation and configuration management that I’ve seen chef work with in the past. This impression is backed up by users of Salt who are clearly using it in their day-to-day operations. So I’m trying it out.

References, etc.

@p3t3r67x0
p3t3r67x0 / openssl_commands.md
Last active May 22, 2024 02:19
Some list of openssl commands for check and verify your keys

openssl

Install

Install the OpenSSL on Debian based systems

sudo apt-get install openssl