Update documentation

main
Vadim vtroshchinskiy 2024-12-30 09:15:21 +01:00
parent 31b15d33a1
commit c3c613fdea
1 changed files with 6 additions and 14 deletions

View File

@ -15,26 +15,18 @@ To install Python dependencies, the `venv` module is used (https://docs.python.o
# Usage
## Older Distributions (18.04)
# Ubuntu 24.04
sudo apt install -y python3.8 python3.8-venv python3-venv libarchive-dev
python3.8 -m venv venvog
. venvog/bin/activate
python3.8 -m pip install --upgrade pip
pip3 install -r requirements.txt
sudo apt install -y python3-flask python3-paramiko opengnsys-flask-executor opengnsys-flask-restx
The `opengnsys-flask-executor` and `opengnsys-flask-restx` packages are available on the OpenGnsys package server.
Run with:
./gitapi.py
## Usage
**Note:** Run as `opengnsys`, as it manages the images located in `/opt/opengnsys/images`.
$ . venvog/bin/activate
$ ./gitapi.py
# Documentation
@ -52,14 +44,14 @@ Python documentation can be generated using a utility like pdoc3 (there are mult
The gitapi is designed to run within an existing opengnsys environment. It should be installed in an ogrepository.
## API Example
## API Examples
### Get list of branches
$ curl -L http://localhost:5000/repositories/linux/branches
{
"branches": [
"master"
"master"
]
}