sanitize
Run the sanitization pipeline on a database snapshot.
clonit sanitize <target> [snapshot_index]Arguments
Section titled “Arguments”| Argument | Description | Required |
|---|---|---|
target |
Name of the target | Yes |
snapshot_index |
Index of the snapshot to sanitize | No (defaults to latest) |
Description
Section titled “Description”Executes a three-step sanitization pipeline on the specified snapshot:
- Restore: The source snapshot is restored into the sanitize destination database (
sanitize_dst_url). - Execute: The sanitization SQL query file (
sanitize_query_file) is executed against the sanitize destination database to scrub, mask, or transform sensitive data. - Dump: The sanitized database is dumped to create a new sanitized snapshot.
The target must have both sanitize_dst_url and sanitize_query_file configured. Use targets add or targets update to set these fields.
Examples
Section titled “Examples”Sanitize the latest snapshot:
clonit sanitize mydbSanitize a specific snapshot by index:
clonit sanitize mydb 0