This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# NOTE: this script is deprecated; | |
# maintained version with SVG icons: https://github.com/glowinthedark/index-html-generator/ | |
# --- | |
# Copyright 2020 glowinthedark | |
# | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python3 | |
""" | |
A utility to stream records from one or many S3 Inventory reports, with a progress bar. | |
./parse-inventory-progress s3://my-bucket/path/to/my/inventory/2019-12-15T00-00Z/manifest.json > out.csv | |
""" | |
import json | |
import csv | |
import gzip | |
import sys |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MIT LICENSE | |
Copyright 2018 Quentin Dufour | |
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: | |
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. | |
THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR TH |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
From 3e7125490ca5c317f6d7b39c727018fb48cc31df Mon Sep 17 00:00:00 2001 | |
From: Stefan Wahren <stefan.wahren@i2se.com> | |
Date: Sat, 1 Sep 2018 16:10:41 +0200 | |
Subject: [PATCH] net: smsc95xx: Fix max MTU value | |
The commit f77f0aee4da4 ("net: use core MTU range checking in USB NIC | |
drivers") introduce a common MTU handling for usbnet. But it's missing | |
the necessary changes for smsc95xx. So set the max MTU to 1500. | |
This patch has been tested on a Raspberry Pi 3. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Diff of the original cc_phone_home and the slightly modified version that supports | |
# including the server pub_keys in the phone_home payload | |
# Original: https://github.com/number5/cloud-init/blob/master/cloudinit/config/cc_phone_home.py | |
# A couple of typos in comment lines in the original were elided to make the diff a bit clearer. | |
# The Centos7 distros I am using do not provide pub_key_dsa. | |
# I am talking to a Rails app with phone_home. | |
# A dummy X-CSRF-Token: 1234567890 in the headers simplifies the code on the Rails side. | |
# I authenticate the phone_home payload by including a token provided in the |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Jenkinsfile VIM syntax highlighting | |
echo 'au BufNewFile,BufRead Jenkinsfile setf groovy' >> ~/.vimrc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
# set -o nounset | |
set -o errexit | |
shopt -s dotglob | |
# Remove oldest .tgz files, if free space less than 50GB | |
# | |
# License: CC0 1.0 or newer | |
# https://creativecommons.org/publicdomain/zero/1.0/ | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
user_name="$1" | |
echo "Removing user: ${user_name}" | |
echo "Deleting Access Keys:" | |
keys=("$(aws iam list-access-keys --user-name "${user_name}" | jq -r '.AccessKeyMetadata[] | .AccessKeyId')") | |
if [[ "${#keys}" -gt "0" ]]; then | |
# shellcheck disable=SC2068 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### variables | |
variable "env" {} | |
variable "riak_count" {} | |
variable "elastic_count" {} | |
### hostname.tpl | |
${name}-${env}-${format("%02s",index)} ${extra} | |
### ansible.tpl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Disk encryption benchmarks: | |
$ cryptsetup benchmark | |
# Tests are approximate using memory only (no storage IO). | |
PBKDF2-sha1 352344 iterations per second | |
PBKDF2-sha256 196215 iterations per second | |
PBKDF2-sha512 156784 iterations per second | |
PBKDF2-ripemd160 237449 iterations per second | |
PBKDF2-whirlpool 73470 iterations per second | |
# Algorithm | Key | Encryption | Decryption |
NewerOlder