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
--- | |
- hosts: unbound_docker | |
become: true | |
handlers: | |
- name: "Re/Start unbound" | |
shell: docker-compose up -d --force-recreate | |
args: | |
chdir: "{{ unbound_compose_dir | default('/opt/unbound') }}" | |
listen: "handler_restart_unbound" |
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 | |
BASEPATH=$(dirname $0) | |
source $BASEPATH/functions.sh | |
LOGFILE="$LOGPATH/$(basename $0).log" | |
exec > >(tee -i $LOGFILE) | |
checkSudo | |
ARRAY="$@" |
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
PHP_VER=$(php -v | head -1 | awk '{print $2}') | |
# Check if extension exists first | |
php -m | grep pgsql | |
# Update brew and install requirements | |
brew update | |
brew install autoconf | |
# Download PHP source and extract |
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 | |
## How many builds do you want to keep | |
KEEP_LAST_BUILDS=5 | |
if [[ $# -lt 2 ]]; then | |
echo "Usage: $(basename $0) 'url' 'project name'" | |
echo "Example: $(basename $0) 'http://jenkins.example.com' 'example'" | |
exit 1 | |
fi |
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 | |
SLEEP=30 | |
if [[ $# -lt 2 ]]; then | |
echo "Usage: $0 <host> <port>" | |
exit | |
fi | |
TESTHOST=$1 |
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
filter { | |
grep { | |
match => [ "message", "(^.+Exception: .+)|(^\s+at .+)|(^at .+)|(^\s+... \d+ more)|(^\s*Caused by:.+)|(^Caused by:.+)" ] | |
add_tag => [ "has_stacktrace" ] | |
} | |
} |
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
input { | |
## WebLogic Server Log | |
file { | |
type => "weblogic" | |
path => [ "/var/log/weblogic/domain/managedserver.log" ] | |
codec => multiline { | |
pattern => "^####" | |
negate => true | |
what => previous | |
} |
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 | |
## use on OSX | |
if [[ $# -eq 0 ]]; then | |
echo "Remove key from known" | |
echo "Usage: $0 <linenum>" | |
else | |
sed -i '' "${1},${1}d" ~/.ssh/known_hosts | |
fi |
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 | |
CURL=`which curl` | |
GAWK=`which gawk` | |
case $1 in | |
10 ) | |
URL="http://www.speedtest2.nl/download/10mb.bin.zip" | |
;; | |
http*) | |
URL=$1 | |
;; |
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 | |
if [ $# -eq 0 ]; then | |
echo "Usage: $0 <path/to/m3u8>" | |
exit | |
fi | |
FILE=$1 | |
TMPFILE="$FILE.new" |
NewerOlder