update organizr to use postgres-shared instead of sqlite
This commit is contained in:
@@ -46,19 +46,21 @@ PostgreSQL Shared is a centralized PostgreSQL 17 database server providing isola
|
||||
| **Resource Limits** | None |
|
||||
| **GPU Required** | No |
|
||||
| **Dependencies** | docker-dataplane network |
|
||||
| **Databases** | `authentik` (Authentik SSO), `gitea` (Git hosting), `postgres` (default/admin) |
|
||||
| **Database Users** | `authentik_user`, `gitea_user`, `postgres` (superuser) |
|
||||
| **Databases** | `authentik` (Authentik SSO), `gitea` (Git hosting), `organizr` (Organizr dashboard), `postgres` (default/admin) |
|
||||
| **Database Users** | `authentik_user`, `gitea_user`, `organizr_user`, `postgres` (superuser) |
|
||||
| **Health Check** | `pg_isready -U postgres` (30s interval) |
|
||||
| **Backup Strategy** | `/backups` volume for pg_dump exports |
|
||||
|
||||
**Initialization**: Databases and users are created manually after first deployment:
|
||||
```bash
|
||||
docker exec -i postgres-shared psql -U postgres <<'EOF'
|
||||
CREATE DATABASE authentik;
|
||||
CREATE USER authentik_user WITH PASSWORD '<password>';
|
||||
GRANT ALL PRIVILEGES ON DATABASE authentik TO authentik_user;
|
||||
EOF
|
||||
```
|
||||
**Initialization**: Databases and users for `authentik` and `gitea` are created by the `postgres-init.sh` script.
|
||||
|
||||
**Adding Organizr Database**:
|
||||
|
||||
1. **Generate a secure password** for the `organizr_user`.
|
||||
2. **In Portainer, navigate to the `postgres-shared` service.**
|
||||
3. **Go to the "Env" tab and add a new environment variable:**
|
||||
* **Name:** `ORGANIZR_DB_PASSWORD`
|
||||
* **Value:** *Your generated password*
|
||||
4. **Redeploy the `postgres-shared` service.** This will trigger the `postgres-init.sh` script to create the `organizr` database and user.
|
||||
|
||||
---
|
||||
|
||||
@@ -241,15 +243,27 @@ Organizr serves as a comprehensive unified dashboard that consolidates all homel
|
||||
| **Network Mode** | Bridge |
|
||||
| **Restart Policy** | `unless-stopped` |
|
||||
| **Volume Mounts** | `~/docker-data/organizr:/config` |
|
||||
| **Environment** | Built-in (no custom env vars) |
|
||||
| **Environment** | `DB_TYPE=pgsql`, `DB_HOST=postgres-shared`, `DB_PORT=5432`, `DB_NAME=organizr`, `DB_USER=organizr_user`, `DB_PASS=${ORGANIZR_DB_PASSWORD}` |
|
||||
| **Resource Limits** | None |
|
||||
| **GPU Required** | No |
|
||||
| **Dependencies** | None (integrates with other services via API) |
|
||||
| **Database** | SQLite at `/config/db/organizrDashboardDb.db` |
|
||||
| **Dependencies** | PostgreSQL Shared |
|
||||
| **Database** | PostgreSQL on `postgres-shared` (database `organizr`) |
|
||||
| **Database Size** | ~5-10MB (typical) |
|
||||
| **Integrated Services** | Jellyfin, Netdata, Uptime Kuma |
|
||||
| **Authentication** | Internal (supports SSO, Plex OAuth, LDAP) |
|
||||
|
||||
**Configuration**:
|
||||
|
||||
1. **In Portainer, navigate to the `organizr` stack.**
|
||||
2. **Go to the "Env" tab and ensure the following environment variables are set:**
|
||||
* `DB_TYPE=pgsql`
|
||||
* `DB_HOST=postgres-shared`
|
||||
* `DB_PORT=5432`
|
||||
* `DB_NAME=organizr`
|
||||
* `DB_USER=organizr_user`
|
||||
* `DB_PASS`: This should be a secret. Create a secret in Portainer named `ORGANIZR_DB_PASSWORD` and set its value to the password you generated for the `organizr_user`.
|
||||
3. **Redeploy the `organizr` stack.**
|
||||
|
||||
---
|
||||
|
||||
## Optimization Layer
|
||||
|
||||
Reference in New Issue
Block a user