You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
440 B
23 lines
440 B
#!/usr/bin/env bash
|
|
|
|
mkdir /root/.ssh
|
|
echo "$SSH_PRIVATE_KEY" > /root/.ssh/id_rsa
|
|
chmod 0600 /root/.ssh/*
|
|
chmod 700 /root/.ssh
|
|
chmod 700 /root
|
|
|
|
case "$DRONE_BRANCH" in
|
|
"production")
|
|
export USER=mabatista1
|
|
export IP=lisbonne.iut-clermont.uca.fr
|
|
export DIR=tbasket
|
|
;;
|
|
"")
|
|
echo '$DRONE_BRANCH is missing' >&2
|
|
exit 1
|
|
;;
|
|
*)
|
|
export USER=tbasket-dev
|
|
export IP=92.132.64.175
|
|
export DIR=/server/TBasket
|
|
esac |