Page MenuHomePhabricator

new-es-password.sh

Authored By
bd808
Nov 4 2016, 9:46 PM
Size
327 B
Referenced Files
None
Subscribers
None

new-es-password.sh

#!/usr/bin/env bash
# Ugly script to generate password data
# for the Tool Labs elasticsearch cluster
USER=${1}
PASS=$(openssl rand -base64 32)
TFILE="$(basename $0).$$.tmp"
echo user=$USER
echo password=\"$PASS\"
echo ---------------------------------
echo $PASS |
htpasswd -cmi $TFILE $USER &>/dev/null
cat $TFILE
rm $TFILE

File Metadata

Mime Type
text/plain; charset=utf-8
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
4116521
Default Alt Text
new-es-password.sh (327 B)

Event Timeline