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
# | |
# File: all_public_repos_to_internal.rake | |
# Author: https://gist.github.com/c0psrul3 | |
# Original Author: https://gist.github.com/ptierno | |
# Original Gist: https://gist.github.com/ptierno/ef57a83afac4442e2a13 | |
# | |
# | |
# Gitlab stuff | |
# ------------ |
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
# The command finds the most recent tag that is reachable from a commit. | |
# If the tag points to the commit, then only the tag is shown. | |
# Otherwise, it suffixes the tag name with the number of additional commits on top of the tagged object | |
# and the abbreviated object name of the most recent commit. | |
git describe | |
# With --abbrev set to 0, the command can be used to find the closest tagname without any suffix: | |
git describe --abbrev=0 | |
# other examples |
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/python | |
import ansible.inventory | |
import ansible.playbook | |
import ansible.runner | |
from ansible import utils | |
from ansible import callbacks | |
def run_playbook(**kwargs): |
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 python | |
# | |
# MongoDB-backed dynamic inventory script for Ansible | |
# http://docs.ansible.com/intro_dynamic_inventory.html | |
import os | |
from argparse import ArgumentParser | |
import pymongo |
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
ansible_ssh_host | |
The name of the host to connect to, if different from the alias you wish to give to it. | |
ansible_ssh_port | |
The ssh port number, if not 22 | |
ansible_ssh_user | |
The default ssh user name to use. | |
ansible_ssh_pass | |
The ssh password to use (this is insecure, we strongly recommend using --ask-pass or SSH keys) | |
ansible_sudo_pass | |
The sudo password to use (this is insecure, we strongly recommend using --ask-sudo-pass) |
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/sh | |
for x | |
do | |
echo "Converting $x" | |
tr -d '\015' < "$x" > "tmp.$x" | |
mv "tmp.$x" "$x" | |
done |
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 | |
# | |
# This script installs and configures couchdb on a fresh Amazon Linux AMI instance. | |
# | |
# Must be run with root privileges | |
# Tested with Amazon Linux AMI release 2011.02.1.1 (ami-8c1fece5) | |
# | |
export BUILD_DIR="$PWD" |
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 | |
########### | |
# Script install and configure ELK stack Server and can be used for adding new clients to this stack. | |
# Last modified 3/3/2016 | |
# Author: Aljo Antony | |
########### | |
# Define colors in case we decide to use them | |
color() { | |
Red='\e[0;31m' |
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
{ | |
"mappings": { | |
"_default_": { | |
"_all": { | |
"enabled": true, | |
"norms": { | |
"enabled": false | |
} | |
}, | |
"dynamic_templates": [ |
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/local/bin/bash | |
# shell script hardening | |
set -euf -o pipefail | |
# | |
# Lets Encrypt Certificate Generator | |
# https://calomel.org/lets_encrypt_client.html | |
# lets_encrypt.sh v0.04 | |
# |
NewerOlder