diff --git a/Controller/mysql_connect.py b/Controller/mysql_connect.py index 9288d16..35c3196 100644 --- a/Controller/mysql_connect.py +++ b/Controller/mysql_connect.py @@ -20,7 +20,7 @@ server = SSHTunnelForwarder( ) def database(query,name,user): server.start() - print(f"SSH Server start {server.local_bind_port}") + print(f"SSH Server start Port:{server.local_bind_port}") mydb = mysql.connector.connect( host="127.0.0.1", port=server.local_bind_port, diff --git a/packages.txt b/packages.txt index 9caf7e7..dd67195 100644 Binary files a/packages.txt and b/packages.txt differ diff --git a/setup-info.sh b/setup-info.sh new file mode 100644 index 0000000..6df89cd --- /dev/null +++ b/setup-info.sh @@ -0,0 +1,22 @@ +#!/bin/bash +## Ordner anlegen +mkdir /root/REPORTS +cd /root/REPORTS + +## APT UPDATE +apt update +apt install python3-pip git -y + +## Add GIT +git init +git remote add orgin https://gitlab.stines.de/sebastian.serfling/REPORTS.git +git fetch +git pull orgin main + +## Install Python +python3 -m pip install virtualenv +python3 -m virtualenv venv +source venv/bin/activate +python3 -m pip install -r packages.txt +python3 main.py +deactivate \ No newline at end of file