Portabase AgentDatabases
MsSQL
Specific configuration for MsSQL.
MsSQL is fully supported by the Portabase agent. We use native sqlpackage tool to ensure consistent and reliable backups and restorations.
Configuration
In your databases.json (or .toml) file, configure the following block.
{
"name": "Database - MsSQL",
"database": "myappdb",
"type": "mssql",
"username": "sa",
"password": "Password!Strong1",
"port": 1433,
"host": "db-mssql",
"generated_id": "..."
}Docker Compose Example
Here is how to configure a MsSQL service alongside the agent.
services:
db-mssql:
container_name: db-mssql
image: mcr.microsoft.com/azure-sql-edge:latest
ports:
- "1433:1433"
environment:
ACCEPT_EULA: "Y"
MSSQL_SA_PASSWORD: "Password!Strong1"
volumes:
- mssql-data:/var/opt/mssql
networks:
- portabase
healthcheck:
test: ["CMD-SHELL", "cat /proc/net/tcp6 | grep -q '059901' || exit 1"]
interval: 10s
timeout: 5s
retries: 20
agent:
image: portabase/agent:latest
# ... agent configuration ...
depends_on:
- db-mssql
networks:
- portabase
networks:
portabase:
external: true
volumes:
mssql-data:If you use localhost as the host (because the agent is on the host machine and not in Docker, or via host-gateway), ensure your database is listening on all interfaces (0.0.0.0) or is accessible from the agent.
Last updated on