diff --git a/README.md b/README.md index 10c389c..dcc6048 100644 --- a/README.md +++ b/README.md @@ -347,6 +347,46 @@ scores in percent. --- +## Configuration (.env files) + +Each backend reads its credentials and paths from a `.env` file in its `backend/` +directory. These files are gitignored — copy the `.env.example` template and fill +in the values before running. + +### pgvector-demo/backend/.env + +```bash +cp pgvector-demo/backend/.env.example pgvector-demo/backend/.env +``` + +| Variable | Description | Example | +|---|---|---| +| `DB_HOST` | PostgreSQL host | `localhost` | +| `DB_PORT` | PostgreSQL host port | `5433` | +| `DB_NAME` | Database name | `vectors_demo` | +| `DB_USER` | Database user | `dl` | +| `DB_PASSWORD` | Database password | — | +| `PHOTOS_DIR` | Absolute path to the photos folder | `/home/user/photos` | + +### oravector-demo/backend/.env + +```bash +cp oravector-demo/backend/.env.example oravector-demo/backend/.env +``` + +| Variable | Description | Example | +|---|---|---| +| `ORA_HOST` | Oracle host | `localhost` | +| `ORA_PORT` | Oracle host port | `37611` | +| `ORA_SERVICE` | Oracle service name (PDB) | `FREEPDB1` | +| `ORA_USER` | User for Python-embedding backend | `vectors_user` | +| `ORA_PASSWORD` | Password for `ORA_USER` | — | +| `ORA_USER_INDB` | User for in-database embedding backend | `vector` | +| `ORA_PASSWORD_INDB` | Password for `ORA_USER_INDB` | — | +| `PHOTOS_DIR` | Absolute path to the photos folder | `/home/user/photos` | + +--- + ## Setup from scratch ### 1. PostgreSQL diff --git a/oravector-demo/backend/.env.example b/oravector-demo/backend/.env.example new file mode 100644 index 0000000..55ce6c6 --- /dev/null +++ b/oravector-demo/backend/.env.example @@ -0,0 +1,8 @@ +ORA_HOST=localhost +ORA_PORT=37611 +ORA_SERVICE=FREEPDB1 +ORA_USER=vectors_user +ORA_PASSWORD=your_password +ORA_USER_INDB=vector +ORA_PASSWORD_INDB=your_password +PHOTOS_DIR=/path/to/photos diff --git a/pgvector-demo/backend/.env.example b/pgvector-demo/backend/.env.example new file mode 100644 index 0000000..c179766 --- /dev/null +++ b/pgvector-demo/backend/.env.example @@ -0,0 +1,6 @@ +DB_HOST=localhost +DB_PORT=5433 +DB_NAME=vectors_demo +DB_USER=dl +DB_PASSWORD=your_password +PHOTOS_DIR=/path/to/photos