{"id":18226409,"url":"https://github.com/mcpt/sentinel","last_synced_at":"2026-02-12T15:30:50.714Z","repository":{"id":260862943,"uuid":"863247909","full_name":"mcpt/Sentinel","owner":"mcpt","description":"A simple automated backup system","archived":false,"fork":false,"pushed_at":"2025-02-13T05:48:39.000Z","size":97,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-03-24T17:52:48.716Z","etag":null,"topics":["backup","backups","cloudflare-r2","go","mariadb","mariadb-backup","s3"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mcpt.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-26T01:12:44.000Z","updated_at":"2025-02-13T05:48:40.000Z","dependencies_parsed_at":"2024-11-03T06:21:17.891Z","dependency_job_id":"5985c9ec-6c74-40a8-b713-1bdd46627b66","html_url":"https://github.com/mcpt/Sentinel","commit_stats":null,"previous_names":["mcpt/sentinel"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcpt%2FSentinel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcpt%2FSentinel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcpt%2FSentinel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mcpt%2FSentinel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mcpt","download_url":"https://codeload.github.com/mcpt/Sentinel/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248288358,"owners_count":21078903,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["backup","backups","cloudflare-r2","go","mariadb","mariadb-backup","s3"],"created_at":"2024-11-04T04:03:28.927Z","updated_at":"2026-02-12T15:30:50.672Z","avatar_url":"https://github.com/mcpt.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Sentinel\n\nSentinel is a robust, modular backup system designed to secure your MySQL/MariaDB databases and files to S3-compatible storage solutions, with support for various compression formats and flexible scheduling.\n\n## Features\n\n- Modular backup system supporting multiple backup sources:\n   - MySQL/MariaDB database backups using mysqldump\n   - File and directory backups with pattern matching\n   - Easy to extend with new backup handlers\n- Advanced compression options:\n   - Support for gzip and zstd compression\n   - Configurable compression levels\n- Flexible storage options:\n   - Compatible with S3, Cloudflare R2, MinIO, and other S3-compatible storage\n   - Configurable upload parameters (part size, concurrency)\n- Configurable via TOML configuration file\n- Debug mode for troubleshooting\n- Temporary directory management\n- Docker support with optional container database backup\n\n## Prerequisites\n\n- Go 1.16+ (for building from source)\n- Docker (optional, for containerized deployment)\n- MySQL/MariaDB (if database backup is enabled)\n- S3-compatible storage account\n\n## Configuration\n\nSentinel uses a TOML configuration file. Here's a sample configuration with all available options:\n\n```toml\n# Backup system configuration\nschedule = \"0 4 * * *\"  # Daily at 4 AM (if not specified, backup will run immediately)\ntemp_dir = \"\"          # Optional: temporary directory for backups\ndebug = false          # Enable debug logging\n\n[compression]\nformat = \"gzip\"        # Supported: \"gzip\", \"zstd\"\nlevel = 3             # Compression level (1-9)\n\n[mysql]\nenabled = false        # Enable/disable MySQL backup\nhost = \"localhost\"\nport = \"3306\"\nuser = \"backup_user\"\npassword = \"backup_password\"\ndatabase = \"myapp\"\ndocker_container = \"\"  # Optional: MySQL docker container name\n\n[filesystem]\nenabled = true\nbase_path = \"/path/to/backup\"\ninclude_patterns = [   # Glob patterns for files to include\n    \"*.txt\",\n    \"*.pdf\",\n    \"config/**\",\n    \"data/**\"\n]\nexclude_patterns = [   # Glob patterns for files to exclude\n    \".git/**\",\n    \"node_modules/**\",\n    \"tmp/**\",\n    \"*.tmp\"\n]\n\n[s3]\nendpoint = \"https://your-endpoint.com\"\nregion = \"auto\"       # Use \"auto\" for services like R2\nbucket = \"your-bucket\"\naccess_key_id = \"your-access-key\"\nsecret_access_key = \"your-secret-key\"\nmax_concurrency = 10  # Maximum concurrent uploads\npart_size = 0        # Multipart upload part size (0 for auto)\n```\n\n## Installation\n\n### Using Docker\n\n1. Clone the repository:\n   ```bash\n   git clone https://github.com/mcpt/sentinel.git\n   ```\n\n2. Build the Docker image:\n   ```bash\n   docker build -t sentinel .\n   ```\n\n3. Create your config.toml file based on the example above.\n\n4. Run the container:\n   ```bash\n   docker run -d --name sentinel \\\n     -v /path/to/your/config.toml:/app/config.toml \\\n     -v /path/to/backup:/data \\\n     sentinel\n   ```\n\n### Building from Source\n\n1. Clone the repository:\n   ```bash\n   git clone https://github.com/yourusername/sentinel.git\n   ```\n\n2. Navigate to the project directory:\n   ```bash\n   cd sentinel\n   ```\n\n3. Build the binary:\n   ```bash\n   go build -o sentinel sentinel/backup-system/main.go\n   ```\n\n4. Create your config.toml and run:\n   ```bash\n   ./sentinel --config /path/to/config.toml\n   ```\n\n## Architecture\n\nSentinel uses a modular architecture with the following components:\n\n- Backup Handlers: Implement the `BackupHandler` interface for different backup sources\n- Storage: S3-compatible storage implementation\n- Compression: Supports multiple compression formats\n- Configuration: TOML-based configuration system\n\n## Development\n\nTo contribute to Sentinel:\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/AmazingFeature`)\n3. Commit your changes (`git commit -m 'Add some AmazingFeature'`)\n4. Push to the branch (`git push origin feature/AmazingFeature`)\n5. Open a Pull Request\n\n### Adding New Backup Handlers\n\nImplement the `BackupHandler` interface to add support for new backup sources:\n\n```go\ntype BackupHandler interface {\n    Backup(ctx context.Context) (string, error)\n}\n```\n\n## License\n\nDistributed under the GPL-3.0 License. See `LICENSE` for more information.\n\n## Acknowledgments\n\n- The Go community\n- Contributors to the AWS SDK for Go\n- Open-source backup solution developers","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmcpt%2Fsentinel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmcpt%2Fsentinel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmcpt%2Fsentinel/lists"}