Skip to content

Instantly share code, notes, and snippets.

!hillside!
!phillip1
!phillycoc1
"hillgo"
#1LaChills
#1hillo
#1phillip
#1philly
#chill
$4philly
readonly BLUE=$(tput setaf 4 2>/dev/null)
readonly SCRIPT_NAME="$(basename "$0")"
readonly CYAN=$(tput setaf 6 2>/dev/null)
readonly YELLOW=$(tput setaf 3 2>/dev/null)
readonly RED=$(tput setaf 1 2>/dev/null)
readonly BIGHT_RED=$(tput setaf 196 2>/dev/null)
readonly RESET=$(tput sgr0 2>/dev/null)
log() {
echo >&2 "${RESET}$(date +"%Y-%m-%d %H:%M:%S") [${1}] [$SCRIPT_NAME] ${2}"
@DrMagPie
DrMagPie / install-elastic-beat.sh
Last active August 14, 2020 13:14
simple POSIX shell compliant script to install Elastic beats on a Debian based system.
#!/bin/sh
set -e
readonly DEFAULT_VERSION="7.2.0"
readonly BEATS="filebeat|metricbeat|packetbeat|auditbeat|heartbeat"
readonly SCRIPT_NAME="$(basename "$0")"
# colors
readonly RED=$(tput setaf 1 2>/dev/null)
readonly BLUE=$(tput setaf 4 2>/dev/null)