Skip to main content

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.

Prerequisites

  • Python 3.8 or higher
  • Google Cloud SDK
  • Google Cloud Service Account with the following permissions:
    • roles/compute.instanceAdmin.v1
    • roles/compute.networkAdmin
    • roles/compute.securityAdmin

Authentication

SnapManager uses Google Cloud Application Default Credentials for authentication. You can set this up in one of two ways:

  1. Service Account Key File (Recommended for production):

    export GOOGLE_APPLICATION_CREDENTIALS="/path/to/service-account-key.json"
    
  2. 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

Example

snapmanager restore \
  --project my-project \
  --zone europe-west1-b \
  --vpc-network default \
  --subnet default \
  --snapshot my-windows-vss-snapshot

This will:

  1. Create a new disk from the VSS snapshot
  2. Create a temporary VM to make the disk bootable
  3. Run necessary Windows boot configuration commands
  4. Create a final VM with the bootable disk
  5. Clean up temporary resources

License

This project is licensed under the MIT License - see the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

snapmanager-0.3.0.tar.gz (18.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

snapmanager-0.3.0-py3-none-any.whl (20.3 kB view details)

Uploaded Python 3

File details

Details for the file snapmanager-0.3.0.tar.gz.

File metadata

  • Download URL: snapmanager-0.3.0.tar.gz
  • Upload date:
  • Size: 18.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.0

File hashes

Hashes for snapmanager-0.3.0.tar.gz
Algorithm Hash digest
SHA256 70d79586f2d40e9751f64cd415fe4b0d94ffd413a04a6e014595f580dfc54abd
MD5 5017737c5f63836bc9d508a50311659c
BLAKE2b-256 982ce299a0ab7bed70cfb23b62e2552db44c53ec596990e079f680159b869dd1

See more details on using hashes here.

File details

Details for the file snapmanager-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: snapmanager-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 20.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.0

File hashes

Hashes for snapmanager-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 57016519e182662e5f751373f0aa1aa70297bbcb4584c06a7c3f57604e12569d
MD5 6db923c8694dd5f88dd1730db3b43441
BLAKE2b-256 f7247254cd5438a6cd41ca63a94732ff60e28c4dc81c2e0d607e90913b65369e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page