Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,9 @@ Create a `.env` file in the root directory or export the variables in your shell
| `SPRING_DATASOURCE_URL` | ✅ | — | JDBC URL, e.g. `jdbc:postgresql://host:5432/db` |
| `SPRING_DATASOURCE_USERNAME` | ✅ | — | Database username |
| `SPRING_DATASOURCE_PASSWORD` | ✅ | — | Database password |
| `SPRING_DATA_REDIS_HOST` | | | Redis hostname |
| `SPRING_DATA_REDIS_HOST` | | `redis` | Redis hostname; used when `REDIS_URL` is not set |
| `SPRING_DATA_REDIS_PORT` | ❌ | `6379` | Redis port |
| `REDIS_URL` | ❌ | — | Full Redis URL (for example, `redis://:password@redis:6379/0`); overrides host and port |
| `HIKARI_MAX_POOL` | ❌ | `10` | Max JDBC connection pool size |
| `SMS_PRICE_PER_SEGMENT` | ❌ | `20.0` | Price per SMS segment (in TZS) |
| `FLEXTUMA_SMS_BEEM_DELIVERY_POLL_INTERVAL_MS` | ❌ | `60000` | Beem delivery-report polling interval in milliseconds |
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ plugins {
}

group = 'com.flexcodelabs'
version = '0.0.38'
version = '0.0.39'
description = 'Flextuma App'

java {
Expand Down
3 changes: 2 additions & 1 deletion docs/deployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ Provide secrets through the platform secret manager, never in the image, reposit
| --- | --- | --- |
| `SPRING_DATASOURCE_URL` | Yes | PostgreSQL JDBC URL, with TLS when supported by the provider. |
| `SPRING_DATASOURCE_USERNAME` / `SPRING_DATASOURCE_PASSWORD` | Yes | Dedicated least-privilege database account. |
| `SPRING_DATA_REDIS_HOST` / `SPRING_DATA_REDIS_PORT` | Yes | Shared Redis service; protect with network controls and authentication/TLS where available. |
| `REDIS_URL` | Recommended for Dokploy | Full Redis URL, e.g. `redis://:password@redis:6379/0`; it overrides host, port, username, password, and database. Use `rediss://` when your provider requires TLS. |
| `SPRING_DATA_REDIS_HOST` / `SPRING_DATA_REDIS_PORT` | Alternative | Use these when a full URL is unavailable; defaults are `redis` and `6379`. |
| `SPRING_JPA_HIBERNATE_DDL_AUTO` | Yes | Set to `validate`; do not use the repository default `update` in production. |
| `HIKARI_MAX_POOL`, `HIKARI_MIN_IDLE` | Recommended | Size across all replicas below PostgreSQL’s connection limit. |
| `SESSION_TIMEOUT` | Recommended | Session lifetime, e.g. `30m`. |
Expand Down
5 changes: 3 additions & 2 deletions src/main/resources/application.properties
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ logging.level.com.flexcodelabs.flextuma=${LOG_LEVEL_FLEXTUMA:INFO}
logging.level.org.springframework.boot.autoconfigure=${LOG_LEVEL_SPRING_BOOT_AUTOCONFIGURE:INFO}
logging.level.com.flexcodelabs.flextuma.core.config.RequestLoggingFilter=${LOG_LEVEL_REQUEST_LOGGING_FILTER:DEBUG}

spring.data.redis.host=${REDIS_HOST:redis}
spring.data.redis.port=${REDIS_PORT:6379}
spring.data.redis.url=${REDIS_URL:}
spring.data.redis.host=${SPRING_DATA_REDIS_HOST:${REDIS_HOST:redis}}
spring.data.redis.port=${SPRING_DATA_REDIS_PORT:${REDIS_PORT:6379}}
spring.data.redis.repositories.enabled=${SPRING_DATA_REDIS_REPOSITORIES_ENABLED:false}

server.servlet.session.timeout=${SESSION_TIMEOUT:30m}
Expand Down