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 | |
# How to use: | |
# | |
# Ubuntu 16.04: apt install -y python-boto OR apt install -y python3-boto | |
# | |
# Specify the default profile on aws/boto profile files or use the optional AWS_PROFILE env var: | |
# AWS_PROFILE=example ./dehydrated -c -d example.com -t dns-01 -k /etc/dehydrated/hooks/route53.py | |
# | |
# Manually specify hosted zone: |
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 groovy | |
/** | |
* Usage: ./SolrExporter.groovy query url [url] | |
* | |
* ./SolrExporter.groovy "id:12345" "http://your.solr.host:8983/solr/core/" | |
* | |
* ./SolrExporter.groovy "id:12345" "http://old.solr.host:8983/solr/core/" "http://new.solr.host:8983/solr/core/" | |
* | |
* |
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
ACTION=="add", SUBSYSTEM=="scsi" , ATTR{type}=="0|7|14", \ | |
RUN+="/bin/sh -c 'echo 180 > /sys$$DEVPATH/timeout'" |
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
def is_public?(ip) | |
["127.0.0.0/8", "192.168.0.0/16", "172.16.0.0/12", "10.0.0.0/8"].map { |net| (IPAddr.new net).include?(IPAddr.new ip) }.none? | |
end |
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 | |
set -e | |
STOREPASS=changeit | |
BACKUP=false | |
function usage { | |
echo "Usage: $0 [-h] [-b] [-s password] /path/to/java/home" | |
echo " -h: show usage" | |
echo " -b: backup keystore file" |