Skip to main content

Deterministic Google Drive backup manager using chained accounts.

Project description

CloudChain

Single-Chain Google Drive Backup Manager A deterministic, account-chain approach to managing unlimited Google Drive backups. DO NOT USE IN AN ATTEMPT TO ABUSE TOC's.


🚀 Overview

CloudChain is a command-line backup manager designed to store files into a linked chain of Google accounts. Instead of juggling random drives, CloudChain enforces a strict naming convention and quota-based rotation so your backups are always deterministic and infinitely expandable.

•	Uses sequential Gmail accounts (<base><NNN>.cloudchain@gmail.com) to extend storage when quotas are hit.
•	Self-contained state: All metadata, configs, and tokens are managed inside a single local root folder.
•	Deterministic rules: Naming and rotation are enforced by code, so you’ll never wonder which account is “next.”

📂 Local Directory Structure

On first run, you’ll be asked for your local backup root (LOCAL_ROOT). CloudChain will create a state directory:

<LOCAL_ROOT>/cloud_backup/
├── client_secret.json        # OAuth credentials
├── accounts.yaml             # Account chain state
├── <base>001.cloudchain/     # Per-account directory
│   ├── token.json
│   ├── uploads.yaml
│   └── mirrored files...
└── ...

All state lives here. Nothing is hidden elsewhere.

🔗 Account Naming

CloudChain enforces a strict naming scheme:

<basename>001.cloudchain@gmail.com


	•	The very first account must end in 001.cloudchain.
	•	Each new account increments numerically (002, 003, …).
	•	Base string (mybackup, familydrive, etc.) is locked at first creation.

If quota reaches ≥95%, CloudChain warns you and requires the next sequential account.


☁️ Remote Storage

All files are uploaded to:

Drive:/backup/

This is fixed and cannot be changed. Every account in the chain mirrors the same folder structure.


🔧 Usage

  1. Initialize
cloudchain init
•	Prompts for local backup root.
•	Enforces base account naming (001.cloudchain).
  1. Add a new account
cloudchain add
•	Checks last account’s quota.
•	Requires next sequential Gmail (<base>002.cloudchain@gmail.com).
  1. Backup files
cloudchain backup /path/to/files
  1. Reset all state
cloudchain reset
•	Wipes local configs and exits.
•	Does not touch remote accounts.

⚠️ Warnings

•	Do not deviate from naming scheme. The system will reject mismatches.
•	Manual Gmail creation required. You must manually create each <base><NNN>.cloudchain@gmail.com before adding it.
•	Drive quota is finite. CloudChain only detects when it’s time to roll over; it cannot expand a single account.

🛠️ Philosophy

CloudChain takes the chaos out of cloud backup by enforcing discipline: • No ad-hoc accounts • No mystery folders • No hidden state

Just a clean, deterministic chain of accounts you can audit at a glance.

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

cloudchain_cli-0.1.0.tar.gz (16.3 kB view details)

Uploaded Source

Built Distribution

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

cloudchain_cli-0.1.0-py3-none-any.whl (15.7 kB view details)

Uploaded Python 3

File details

Details for the file cloudchain_cli-0.1.0.tar.gz.

File metadata

  • Download URL: cloudchain_cli-0.1.0.tar.gz
  • Upload date:
  • Size: 16.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.8

File hashes

Hashes for cloudchain_cli-0.1.0.tar.gz
Algorithm Hash digest
SHA256 be1e6f4b153b577d7661ed6f42233137e92ac2694ac403b835f5c12754751ef8
MD5 997a4d8904cee333982bb86da8476e11
BLAKE2b-256 8ed3b44b02f164615ae2e390a8670f94d1d497cd423ef3ca94ef708a97c25279

See more details on using hashes here.

File details

Details for the file cloudchain_cli-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: cloudchain_cli-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 15.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.8

File hashes

Hashes for cloudchain_cli-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 780913c435bf5f993f7a217c35b30494bfd80a6bee2f9283e37eda683ee875c5
MD5 2c65f01a2251d37bdd84f62f1ee49e26
BLAKE2b-256 5ee83780294427a9a0f289536a9b0c115e84dd0d49b7e2f2fae3def0e993d6cb

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