Skip to content

Instantly share code, notes, and snippets.

@BuffaloWill
Created September 3, 2016 17:27
Show Gist options
  • Save BuffaloWill/aecd5473a8d7540e8f4ddb226c1ff901 to your computer and use it in GitHub Desktop.
Save BuffaloWill/aecd5473a8d7540e8f4ddb226c1ff901 to your computer and use it in GitHub Desktop.
Reset Password for a User with Installed version
#!/bin/sh
cmd=`basename $0`
CWD=`pwd`
SCRIPTDIR=/opt/Serpico/embedded/bin
EMBEDDED=/opt/Serpico/embedded
SERPDIR=/opt/Serpico/Serpico
uname=$1
pass=$2
cd $CWD
unset GEM_HOME
unset GEM_PATH
unset GEM_ROOT
unset RUBY_ENGINE
unset RUBY_ROOT
PATH=$EMBEDDED:$SCRIPTDIR:$PATH
cd $SERPDIR
$SCRIPTDIR/ruby scripts/manage_users.rb -u $uname -p $pass
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment