Makes VSS snapshot disks bootable in Google Cloud
Project description
SnapManager
A tool for managing VSS-enabled snapshots in Google Cloud Platform. Currently supports restoring VSS snapshots and creating bootable VM instances from them.
Features
- Restore VSS-enabled snapshots to bootable VM instances
- Handles all the complexity of making Windows disks bootable
- Clean and user-friendly command-line interface
- Detailed progress tracking and error reporting
Prerequisites
- Python 3.8 or higher
- Google Cloud SDK
- Google Cloud Service Account with the following permissions:
roles/compute.instanceAdmin.v1roles/compute.networkAdminroles/compute.securityAdmin
Authentication
SnapManager uses Google Cloud Application Default Credentials for authentication. You can set this up in one of two ways:
-
Service Account Key File (Recommended for production):
export GOOGLE_APPLICATION_CREDENTIALS="/path/to/service-account-key.json"
-
User Credentials (Good for development):
gcloud auth application-default login
Installation
pip install snapmanager
Usage
# Show help
snapmanager restore --help
# Restore a VSS snapshot
snapmanager restore \
--project YOUR_PROJECT_ID \
--zone ZONE \
--vpc-network NETWORK_NAME \
--subnet SUBNET_NAME \
--snapshot SNAPSHOT_NAME
Command Arguments
--project: Google Cloud project ID where the snapshot and new VM will be created--zone: Google Cloud zone where the new VM will be created--vpc-network: VPC network to attach the new VM to--subnet: Subnet within the VPC network for the new VM--snapshot: Name of the VSS-enabled snapshot to restore from--verbose: Show detailed progress information for each step
How It Works
- Creates a temporary Windows Server VM in the specified VPC network and subnet
- Creates a firewall rule to allow WinRM (port 5986) access to the temporary VM
- Attaches the disk created from the VSS snapshot to the temporary VM
- Configures Windows boot configuration using the temporary VM
- Detaches the disk from the temporary VM
- Deletes the temporary VM
Example
snapmanager restore \
--project my-project \
--zone europe-west1-b \
--vpc-network default \
--subnet default \
--snapshot my-windows-vss-snapshot
This will:
- Create a new disk from the VSS snapshot
- Create a temporary VM to make the disk bootable
- Run necessary Windows boot configuration commands
- Create a final VM with the bootable disk
- Clean up temporary resources
Contributing
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file snapmanager-0.2.9.tar.gz.
File metadata
- Download URL: snapmanager-0.2.9.tar.gz
- Upload date:
- Size: 19.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f0ae2fb809494e61596f7f2eaaaf4cbba0c26ccb3ccdef61d96055e42fdf7a9f
|
|
| MD5 |
2d880ca3dbec6d71b5f869cb2f0d41e8
|
|
| BLAKE2b-256 |
ef3e3ea51bf1fea614c9a593317c8bc3d6f5595e6fe7d4e37b20ff3409942e35
|
File details
Details for the file snapmanager-0.2.9-py3-none-any.whl.
File metadata
- Download URL: snapmanager-0.2.9-py3-none-any.whl
- Upload date:
- Size: 20.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.12.0
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1afee1c706561843f3d2f9c73c577a3b012fd0204cb2f1d06c9d288f566e7c90
|
|
| MD5 |
2d7a37f6f1ffda5536950adb0599a1b8
|
|
| BLAKE2b-256 |
1d815397e8287b1ff053fe90ab8bfa27bd88c40a4524b2093f2d0f45377283f5
|