restore_database
Restore a SQL Server database from a .bak backup file, with options to replace existing database, move files, and auto-disconnect users.
Instructions
Restore a SQL Server database from a .bak file
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fileMoves | No | Optional map of logical file names to new physical paths | |
| backupPath | Yes | Full path to the backup file (e.g., /var/opt/mssql/backup/mydb.bak) | |
| withReplace | No | Replace existing database if it exists (default: false) | |
| databaseName | Yes | Name of the database to restore | |
| autoDisconnect | No | Automatically disconnect users before restore (default: false) |