Create readme.html
This commit is contained in:
parent
21b9b246d0
commit
252f2eea9d
1 changed files with 106 additions and 0 deletions
106
readme.html
Normal file
106
readme.html
Normal file
|
|
@ -0,0 +1,106 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Self-Hosted M365 Backup - Documentation</title>
|
||||
<link rel="stylesheet" href="https://unpkg.com/pico.css">
|
||||
<style>
|
||||
body { max-width: 900px; margin: auto; padding: 2rem; }
|
||||
pre { background: #f4f4f4; padding: 1rem; overflow-x: auto; }
|
||||
h1, h2, h3 { margin-top: 2rem; }
|
||||
code { background: #eee; padding: 0.2rem 0.4rem; border-radius: 4px; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Self-Hosted M365 Backup</h1>
|
||||
<p>A self-hosted, open-source tool to back up Microsoft 365 mailboxes to standard <code>.eml</code> files. It features a web UI for managing backups, background tasks, search, preview functionality, and secure Microsoft OAuth 2.0 login.</p>
|
||||
|
||||
<h2>Features</h2>
|
||||
<ul>
|
||||
<li><strong>Web-Based Management Panel:</strong> Modern web interface for all operations.</li>
|
||||
<li><strong>Secure Authentication:</strong> Microsoft Identity Platform OAuth 2.0 login with MFA support.</li>
|
||||
<li><strong>Selective Backup:</strong> Choose specific users from the tenant list.</li>
|
||||
<li><strong>Date Filtering:</strong> Back up items by date range.</li>
|
||||
<li><strong>Background Tasks:</strong> Large jobs run asynchronously via Celery + Redis.</li>
|
||||
<li><strong>Task Status Dashboard:</strong> Monitor task progress and results.</li>
|
||||
<li><strong>Interactive Restore Portal:</strong>
|
||||
<ul>
|
||||
<li>Navigation through mailbox folders</li>
|
||||
<li>List of emails in selected folder</li>
|
||||
<li>In-browser email preview without downloading</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><strong>Privacy-by-Design:</strong> Email previews blurred by default, hover-to-reveal for admins.</li>
|
||||
<li><strong>Full-Text Search:</strong> Search subject and body of emails.</li>
|
||||
<li><strong>Automated Installation:</strong> Single <code>install.sh</code> script deploys the app on Ubuntu.</li>
|
||||
</ul>
|
||||
|
||||
<h2>Architecture</h2>
|
||||
<ul>
|
||||
<li><strong>Backend:</strong> Python, Flask</li>
|
||||
<li><strong>Web Server:</strong> Gunicorn + Nginx (Reverse Proxy)</li>
|
||||
<li><strong>Background Tasks:</strong> Celery</li>
|
||||
<li><strong>Queue/Broker:</strong> Redis</li>
|
||||
<li><strong>Frontend:</strong> HTML, Pico.css, HTMX</li>
|
||||
<li><strong>Authentication:</strong> Microsoft Identity Platform (OAuth 2.0)</li>
|
||||
</ul>
|
||||
|
||||
<h2>Installation Guide</h2>
|
||||
|
||||
<h3>I. Azure Portal Configuration</h3>
|
||||
<ol>
|
||||
<li><strong>App Registration:</strong>
|
||||
<ul>
|
||||
<li>Go to <code>portal.azure.com</code> → Azure Active Directory → App registrations → + New registration</li>
|
||||
<li>Name the app (e.g., <code>M365-Backup-Tool</code>) and click Register</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><strong>API Permissions:</strong>
|
||||
<ul>
|
||||
<li>Microsoft Graph → Add Permissions</li>
|
||||
<li>Application Permissions: <code>User.Read.All</code>, <code>Mail.Read.All</code></li>
|
||||
<li>Delegated Permissions: <code>User.Read</code></li>
|
||||
<li>Click "Grant admin consent"</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><strong>Redirect URI:</strong>
|
||||
<ul>
|
||||
<li>Authentication → + Add platform → Web</li>
|
||||
<li>Enter: <code>https://<your_server_ip>/get_token</code></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><strong>Client Secret:</strong>
|
||||
<ul>
|
||||
<li>Certificates & secrets → + New client secret</li>
|
||||
<li>Copy the secret value immediately</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ol>
|
||||
<p>Required info: <code>Tenant ID</code>, <code>Client ID</code>, <code>Client Secret Value</code></p>
|
||||
|
||||
<h3>II. Server Installation</h3>
|
||||
<ol>
|
||||
<li>Requirements: Fresh Ubuntu 22.04 LTS server</li>
|
||||
<li>Copy <code>install.sh</code> to the server</li>
|
||||
<li>Make it executable: <pre>chmod +x install.sh</pre></li>
|
||||
<li>Run the script: <pre>sudo ./install.sh</pre></li>
|
||||
<li>Provide Azure credentials and list of admin emails</li>
|
||||
<li>Wait for installation to complete; script outputs server access IP</li>
|
||||
</ol>
|
||||
|
||||
<h2>Usage</h2>
|
||||
<ul>
|
||||
<li>Open browser: <code>https://<your_server_ip></code></li>
|
||||
<li>Accept security warning (self-signed cert)</li>
|
||||
<li>Login with authorized Microsoft account</li>
|
||||
<li><strong>New Backup:</strong> Start a new backup task</li>
|
||||
<li><strong>Existing Backups:</strong> Browse, search, preview backups</li>
|
||||
<li><strong>Tasks:</strong> Monitor background tasks and status</li>
|
||||
</ul>
|
||||
|
||||
<h2>License</h2>
|
||||
<p>Open-source, MIT License.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Loading…
Reference in a new issue