Harden database startup for Portainer
This commit is contained in:
@@ -154,6 +154,12 @@ not need to bind-mount individual files like `database/init.sql` or
|
||||
`mqtt/mosquitto.conf`. This avoids file-versus-directory mount errors in
|
||||
Portainer Git stacks.
|
||||
|
||||
The backend receives PostgreSQL connection settings as separate variables
|
||||
(`POSTGRES_HOST`, `POSTGRES_DB`, `POSTGRES_USER`, `POSTGRES_PASSWORD`) and
|
||||
builds the SQLAlchemy URL internally. This avoids broken database URLs when the
|
||||
password contains special characters. The backend also retries the database
|
||||
connection during startup to tolerate Portainer service/DNS startup delays.
|
||||
|
||||
### 4. Verify
|
||||
|
||||
Open:
|
||||
|
||||
Reference in New Issue
Block a user