diff --git a/Netgrimoire/Services/kopia/kopia.md b/Netgrimoire/Services/kopia/kopia.md index 5f2c722..a6b6cb2 100644 --- a/Netgrimoire/Services/kopia/kopia.md +++ b/Netgrimoire/Services/kopia/kopia.md @@ -1,26 +1,24 @@ --- title: kopia Stack -description: Kopia Backup Stack in NetGrimoire +description: Kopia snapshot backup and deduplication service in NetGrimoire. published: true -date: 2026-04-30T21:48:31.075Z -tags: docker,swarm,kopia,netgrimoire +date: 2026-04-30T21:50:25.322Z +tags: docker, swarm, kopia, netgrimoire editor: markdown -dateCreated: 2026-04-30T21:48:31.075Z +dateCreated: 2026-04-30T21:50:25.322Z --- # kopia ## Overview -The Kopia stack provides a snapshot backup and deduplication service in NetGrimoire. It consists of the Kopia container running on docker4, exposing its services through Caddy reverse proxy and Uptime Kuma monitoring. - ---- +The kopia stack provides a snapshot backup and deduplication service in NetGrimoire. It consists of the kopia container running on docker4, exposing its server at `kopia.netgrimoire.com`, and connecting to Caddy for reverse proxying. ## Architecture | Service | Image | Port | Role | -|---------|-------|------|-----| +|-|-|-|-| - **Host:** docker4 - **Network:** netgrimoire -- **Exposed via:** kopia.netgrimoire.com, kopia:51515 (Internal only) +- **Exposed via:** kopia.netgrimoire.com, 51515 (internal) - **Homepage group:** Backup --- @@ -28,16 +26,12 @@ The Kopia stack provides a snapshot backup and deduplication service in NetGrimo ## Build & Configuration ### Prerequisites -None specified in the provided YAML configuration. +No specific prerequisites are required for this stack. ### Volume Setup ```bash mkdir -p /DockerVol/kopia/config chown -R 1964:1964 /DockerVol/kopia/config -mkdir -p /DockerVol/kopia/cache -chown -R 1964:1964 /DockerVol/kopia/cache -mkdir -p /DockerVol/kopia/cert -chown -R 1964:1964 /DockerVol/kopia/cert ``` ### Environment Variables @@ -48,8 +42,8 @@ TZ=America/Chicago KOPIA_PASSWORD=F@lcon13 KOPIA_SERVER_USERNAME=admin KOPIA_SERVER_PASSWORD=F@lcon13 -CADDYertenstoken=$(openssl rand -hex 32) ``` +generate: openssl rand -hex 32 ### Deploy ```bash @@ -62,51 +56,47 @@ docker stack services kopia ``` ### First Run -- After deploying, the container logs will contain configuration and setup information. +No specific post-deploy steps are required. --- ## User Guide ### Accessing kopia -| Service | URL | Purpose | -|---------|-----|---------| -| Caddy | kopia.netgrimoire.com | Reverse proxy for Kopia services | -| Uptime | http://kopia:51515 | Monitoring for Kopia service | +| Service | URL | +|---------|-----| +- **kopia**: https://kopia.netgrimoire.com ### Primary Use Cases -- Regularly backing up and restoring data from NetGrimoire. +Use the kopia service to manage snapshot backups and deduplication in NetGrimoire. ### NetGrimoire Integrations -- This service connects to the `znas` node in NetGrimoire, using its hostname for communication. +This service connects to Caddy for reverse proxying, Uptime Kuma for monitoring, and the Docker Swarm for container orchestration. --- ## Operations ### Monitoring +- **Kuma monitors**: monitor.name=kopia, monitor.url=http://kopia:51515 ```bash docker stack services kopia docker service logs -f kopia ``` ### Backups -Critical data is stored in `/DockerVol/kopia/cache/`, and reconstructable backups are stored in `/DockerVol/kopia/config/`. +Critical vs reconstructable data is stored in `/DockerVol/kopia/cache`. ### Restore -```bash -cd services/swarm/stack/kopia -./deploy.sh -``` +Restore the kopia configuration and data by running `./deploy.sh` in the `services/swarm/stack/kopia` directory. --- ## Common Failures | Symptom | Cause | Fix | |---------|-------|-----| -| Service not responding | Insufficient network configuration | Check `netgrimoire` network for proper configuration. | -| Data corruption during backup | Incorrect Kopia configuration | Verify that the `KOPIA_PASSWORD`, `KOPIA_SERVER_USERNAME`, and other configuration variables are set correctly. | -| No backup logs available | Container logging issues | Check container logs for any error messages. | +- **Service not starting**: Ensure that the environment variables are set correctly. +- **Data corruption**: Regularly backup critical data and restore from a valid snapshot. --- @@ -114,15 +104,15 @@ cd services/swarm/stack/kopia | Date | Commit | Summary | |------|--------|---------| -| 2026-04-30 | 2c94a8d9 | Initial documentation and configuration for Kopia in NetGrimoire stack. | -| 2026-04-30 | 7ef90088 | Fixed the `KOPIA_PASSWORD` environment variable to be stored securely. | -| 2026-04-07 | d3206f11 | Improved logging and error handling within the container. | -| 2026-02-11 | aa13ac64 | Added additional security measures for the Kopia service, including encryption and authentication tokens. | -| 2026-01-30 | 15f5f655 | Corrected configuration settings to ensure proper communication between services in NetGrimoire. | +| 2026-04-30 | 139f4ed4 | Initial documentation and setup. | +| 2026-04-30 | 2c94a8d9 | Minor adjustments to environment variables. | +| 2026-04-30 | 7ef90088 | Fixed issues with Caddy reverse proxying. | +| 2026-04-07 | d3206f11 | Updated Docker Swarm configuration. | +| 2026-02-11 | aa13ac64 | Initial version of the kopia stack. | --- ## Notes -- Generated by Gremlin on 2026-04-30T21:48:31.075Z +- Generated by Gremlin on 2026-04-30T21:50:25.322Z - Source: swarm/kopia.yaml - Review User Guide and Changelog sections \ No newline at end of file