Updated some things for infrastructure
This commit is contained in:
parent
8bb37bbc21
commit
c5b595ad40
3 changed files with 14 additions and 2 deletions
|
@ -4,6 +4,8 @@ WORKDIR /app
|
|||
|
||||
COPY requirements.txt .
|
||||
|
||||
RUN apk install sqlite3
|
||||
|
||||
RUN pip install -r requirements.txt
|
||||
|
||||
COPY /src .
|
||||
|
|
|
@ -6,6 +6,8 @@ RUN apt-get -y update && apt-get -y upgrade
|
|||
|
||||
COPY requirements.txt .
|
||||
|
||||
RUN apk install sqlite3
|
||||
|
||||
RUN pip install -r requirements.txt
|
||||
|
||||
COPY /src .
|
||||
|
|
12
requests.sh
12
requests.sh
|
@ -2,7 +2,7 @@
|
|||
|
||||
ACTION=$1
|
||||
VALUE=$2
|
||||
ACTIONS=(login register rcvpw username data csv)
|
||||
ACTIONS=(login register rcvpw username data csv prod_data prod_csv)
|
||||
|
||||
print_help(){
|
||||
echo "Usage: $0 ACTION [TOKEN|INPUT_TYPE]"
|
||||
|
@ -41,9 +41,17 @@ case $ACTION in
|
|||
curl localhost:5000/data
|
||||
;;
|
||||
"${ACTIONS[5]}") # get all data from behametricsserver
|
||||
echo "get data action"
|
||||
echo "get csv from input action"
|
||||
curl localhost:5000/data/csv/"${VALUE}"
|
||||
;;
|
||||
"${ACTIONS[6]}") # get all data from behametricsserver
|
||||
echo "get prod data action"
|
||||
curl behavior.marcocamenzind.ch:5000/data
|
||||
;;
|
||||
"${ACTIONS[7]}") # get all data from behametricsserver
|
||||
echo "get prod csv from input action"
|
||||
curl behavior.marcocamenzind.ch:5000/data/csv/"${VALUE}"
|
||||
;;
|
||||
*)
|
||||
echo "Error: Action not available"
|
||||
echo
|
||||
|
|
Loading…
Reference in a new issue