mirror of
https://github.com/tuna/tunasync.git
synced 2025-12-25 22:02:46 +00:00
Bumps [golang.org/x/crypto](https://github.com/golang/crypto) from 0.36.0 to 0.45.0. - [Commits](https://github.com/golang/crypto/compare/v0.36.0...v0.45.0) --- updated-dependencies: - dependency-name: golang.org/x/crypto dependency-version: 0.45.0 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> |
||
|---|---|---|
| .github/workflows | ||
| .umlrootfs | ||
| .vscode | ||
| autocomplete | ||
| cmd | ||
| docs | ||
| internal | ||
| manager | ||
| systemd | ||
| tests | ||
| worker | ||
| .gitignore | ||
| .testpackages.txt | ||
| LICENSE | ||
| Makefile | ||
| README.md | ||
| go.mod | ||
| go.sum | ||
| package.json | ||
tunasync
Get Started
Download
Pre-built binary for Linux x86_64 and ARM64 is available at Github releases.
Design
# Architecture
- Manager: Central instance for status and job management
- Worker: Runs mirror jobs
+------------+ +---+ +---+
| Client API | | | Job Status | | +----------+ +----------+
+------------+ | +----------------->| |--->| mirror +---->| mirror |
+------------+ | | | w | | config | | provider |
| Worker API | | H | | o | +----------+ +----+-----+
+------------+ | T | Job Control | r | |
+------------+ | T +----------------->| k | +------------+ |
| Job/Status | | P | Start/Stop/... | e | | mirror job |<----+
| Management | | S | | r | +------^-----+
+------------+ | | Update Status | | +---------+---------+
+------------+ | <------------------+ | | Scheduler |
| BoltDB | | | | | +-------------------+
+------------+ +---+ +---+
# Job Run Process
PreSyncing Syncing Success
+-----------+ +----------+ +-----------+ +-------------+ +--------------+
| pre-job +--+->| pre-exec +--->| job run +--->| post-exec +-+-->| post-success |
+-----------+ ^ +----------+ +-----------+ +-------------+ | +--------------+
| |
| +-----------------+ | Failed
+----------------+ post-fail |<---------------+
+-----------------+
Building
Go version: 1.22
# for native arch
> make all
# for other arch
> make ARCH=linux-arm64 all
Binaries are in build-$ARCH/, e.g., build-linux-amd64/.