...
This commit is contained in:
parent
19988900c6
commit
776f89af69
16
README.md
16
README.md
@ -2,19 +2,15 @@
|
|||||||
|
|
||||||
new version of threefold, minimalistic
|
new version of threefold, minimalistic
|
||||||
|
|
||||||
|
## install
|
||||||
|
|
||||||
## to debug / develop
|
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
hero git clone -u git@git.ourworld.tf:tfgrid/www_threefold4.git
|
hero git clone -u git@git.ourworld.tf:tfgrid/www_threefold4.git
|
||||||
cd ~/code/git.ourworld.tf/tfgrid/www_threefold4
|
~/code/git.ourworld.tf/tfgrid/www_threefold4/install.sh
|
||||||
source myenv.sh
|
|
||||||
# to test an example
|
|
||||||
cd poc
|
|
||||||
python server.py
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## to add package to pip
|
## to start the server for seeing the website
|
||||||
|
|
||||||
add it to https://git.ourworld.tf/projectmycelium/hero_server/src/branch/main/requirements.txt
|
```bash
|
||||||
|
~/code/git.ourworld.tf/tfgrid/www_threefold4/start.sh
|
||||||
|
```
|
||||||
|
17
install.sh
17
install.sh
@ -4,21 +4,12 @@ BASE_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|||||||
source ${BASE_DIR}/myenv.sh
|
source ${BASE_DIR}/myenv.sh
|
||||||
cd $BASE_DIR
|
cd $BASE_DIR
|
||||||
|
|
||||||
python3 -m pip install -r "$BASE_DIR/requirements.txt"
|
python3 -m pip install -r "$BASE_DIR/requirements.txt"
|
||||||
|
pip install --upgrade pip
|
||||||
# pip freeze > requirements.txt
|
|
||||||
|
|
||||||
#to make sure we have the paths towards hero in our library
|
|
||||||
|
|
||||||
PYTHON_VERSION=$(python3 -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')")
|
PYTHON_VERSION=$(python3 -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')")
|
||||||
echo "$BASE_DIR/lib" > "${VENV_DIR}/lib/python${PYTHON_VERSION}/site-packages/herolib.pth"
|
|
||||||
|
|
||||||
#for osx
|
# echo "$BASE_DIR/lib" > "${VENV_DIR}/lib/python${PYTHON_VERSION}/site-packages/herolib.pth"
|
||||||
# pip3 install psycopg2-binary
|
|
||||||
# psycopg2
|
|
||||||
|
|
||||||
echo "OK"
|
echo "OK"
|
||||||
|
|
||||||
|
|
||||||
python3 -m pip install -r "requirements.txt"
|
|
||||||
pip install --upgrade pip
|
|
||||||
|
4
start.sh
4
start.sh
@ -1,9 +1,11 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -ex
|
set -e
|
||||||
BASE_DIR="$(cd "$(dirname "$0")" && pwd)"
|
BASE_DIR="$(cd "$(dirname "$0")" && pwd)"
|
||||||
cd $BASE_DIR
|
cd $BASE_DIR
|
||||||
|
|
||||||
source myenv.sh
|
source myenv.sh
|
||||||
|
|
||||||
cd poc
|
cd poc
|
||||||
|
set +ex
|
||||||
|
open http://127.0.0.1:8001
|
||||||
python server.py
|
python server.py
|
||||||
|
Loading…
Reference in New Issue
Block a user