2017-09-17 23:24:11 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
#
|
|
|
|
# the directory where Teleport binaries will be located
|
|
|
|
#
|
|
|
|
BINDIR=/usr/local/bin
|
|
|
|
|
|
|
|
#
|
|
|
|
# the directory where Teleport will keep its state/data
|
|
|
|
#
|
|
|
|
VARDIR=/var/lib/teleport
|
|
|
|
|
2017-09-19 19:54:02 +00:00
|
|
|
[ ! $(id -u) != "0" ] || { echo "ERROR: You must be root"; exit 1; }
|
2017-09-17 23:24:11 +00:00
|
|
|
cd $(dirname $0)
|
|
|
|
mkdir -p $VARDIR $BINDIR
|
2022-03-03 03:25:23 +00:00
|
|
|
cp -f teleport tctl tsh tbot $BINDIR/ || exit 1
|
2018-07-20 00:45:03 +00:00
|
|
|
|
2021-04-29 05:17:48 +00:00
|
|
|
#
|
|
|
|
# What operating system is the user running?
|
|
|
|
#
|
|
|
|
unameOut="$(uname -s)"
|
|
|
|
case "${unameOut}" in
|
|
|
|
Linux*) machine=linux;;
|
|
|
|
Darwin*) machine=darwin;;
|
|
|
|
CYGWIN*) machine=cygwin;;
|
|
|
|
MINGW*) machine=minGw;;
|
|
|
|
*) machine="UNKNOWN:${unameOut}"
|
|
|
|
esac
|
|
|
|
|
2018-07-20 00:45:03 +00:00
|
|
|
echo "Teleport binaries have been copied to $BINDIR"
|
2021-04-29 05:17:48 +00:00
|
|
|
echo ""
|
|
|
|
echo "Thanks for installing Teleport."
|
|
|
|
echo ""
|
|
|
|
echo "Is it OK if we collect some info about your install?"
|
|
|
|
echo "Please run this command to send in a survey."
|
2021-04-30 15:45:53 +00:00
|
|
|
echo "Optional: Replace email to join our newsletter and get a swag package."
|
|
|
|
echo "$ curl -X POST https://usage.teleport.dev -F OS=${machine} -F use-case=\"access my ...\" -F email=\"alice@example.com\""
|
2021-04-29 05:17:48 +00:00
|
|
|
echo ""
|
|
|
|
echo "Otherwise, ignore!"
|