docs(gremlin): update manyfold

This commit is contained in:
traveler 2026-04-28 15:44:22 -05:00
parent 4a922db5d2
commit 0d9258b66b

View file

@ -1,45 +1,38 @@
# manyfold # manyfold
## Overview ## Overview
The Manyfold stack is a NetGrimoire service that provides a web-based platform for machine learning tasks, utilizing the Manyfold3D application. The manyfold stack is a Docker Compose configuration for running the Manyfold application in NetGrimoire, along with its dependent services such as PostgreSQL, Redis, and Caddy. The main purpose of this stack is to provide a stable environment for users to access and utilize the Manyfold service.
--- ---
## Architecture ## Architecture
| Service | Image | Port | Role | | Service | Image | Port | Role |
|-|-|-|-| |---------|-------|-----|------|
- **Manyfold** | `ghcr.io/manyfold3d/manyfold:latest` | 3214 | Web Application | - **Host:** docker4
- **Postgres** | `postgres:15` | - | Database | - **Network:** netgrimoire
- **Redis** | `redis:7` | - | Cache | - **Exposed via:** `caddy manyfold.com:3214`
- **Homepage group:** `homepage`
Exposed via: `caddy myfold.localhost`
Homepage group: `homepage.group: manyfold`
--- ---
## Build & Configuration ## Build & Configuration
### Prerequisites ### Prerequisites
None This stack requires a working Docker Swarm environment with the manager running as `znas` and worker nodes running as `docker4`.
### Volume Setup ### Volume Setup
```bash ```bash
mkdir -p /DockerVol/models mkdir -p /DockerVol/manyfold
chown -R 1964:1964 /DockerVol/models chown -R docker:docker /DockerVol/manyfold
``` ```
### Environment Variables ### Environment Variables
```bash ```bash
# generate: openssl rand -hex 32 generate: openssl rand -hex 32
PUID=1964 PUID=1964
PGID=1964 PGID=1964
SECRET_KEY_BASE="..." SECRET_KEY_BASE=OD0CLgELUEWGoZ8IUnduGbxhyhh4vgjMBxBAjyopNOkATWIEWSYeWRDdfY6ulX2Fj7zuUp9dpgzjoFatNviLD8E5Cv2815eDrZxH9gNb52Taur0LzqBPk25yLCvsnjXK
DATABASE_ADAPTER=postgresql
DATABASE_HOST=postgres
DATABASE_PORT=5432
DATABASE_USER=manyfold
DATABASE_PASSWORD=F@lcon13
REDIS_URL=redis://redis:6379/1 REDIS_URL=redis://redis:6379/1
``` ```
@ -54,7 +47,7 @@ docker stack services manyfold
``` ```
### First Run ### First Run
No specific steps required Run `./deploy.sh` to initialize the Docker Swarm environment and start the Manyfold service.
--- ---
@ -62,15 +55,15 @@ No specific steps required
### Accessing manyfold ### Accessing manyfold
| Service | URL | Purpose | | Service | URL | Purpose |
|-|-|-| |---------|-----|---------|
- **Manyfold** | `http://myfold.localhost:3214` | Web Application | - **Manyfold:** `http://manyfold.com:3214`
- **Caddy:** `https://caddy.dnsnetgrimoire[.]io`
### Primary Use Cases ### Primary Use Cases
1. Machine learning tasks, such as prediction and data analysis. To access the Manyfold application, navigate to `http://manyfold.com:3214` in your web browser.
### NetGrimoire Integrations ### NetGrimoire Integrations
- Integrated with Postgres database for data storage. This stack connects to other services such as Caddy and Kuma for monitoring and logging purposes.
- Connected to Redis cache for faster data access.
--- ---
@ -79,44 +72,40 @@ No specific steps required
### Monitoring ### Monitoring
```bash ```bash
docker stack services manyfold docker stack services manyfold
docker service logs -f manyfold | grep "kuma.*" docker service logs -f manyfold
``` ```
### Backups ### Backups
Critical: `/DockerVol/models` Critical data should be stored in `/DockerVol/manyfold` to ensure recoverability. Regular backups can be performed using the `backup.sh` script.
Reconstructable: `/DockerVol/other` (adjust according to your needs)
### Restore ### Restore
```bash Run `./deploy.sh` to restore the Docker Swarm environment and start the Manyfold service.
cd services/swarm/stack/manyfold
./deploy.sh
```
--- ---
## Common Failures ## Common Failures
| Failure Mode | Symptom | Cause | Fix | | Failure Mode | Symptoms | Cause | Fix |
|-|-|-|-| |-------------|----------|------|-----|
1. **Database connection issue** | Error message: "database connection failed" | Postgres not running or credentials incorrect | Check Postgres logs, restart Postgres service, verify database credentials. | PostgreSQL | Connection error | Service not running | Check service logs, restart service |
2. **Cache issue** | Slow response time or cache miss | Redis not running or configuration incorrect | Check Redis logs, restart Redis service, verify Redis configuration. | Redis | Connection error | Service not running | Check service logs, restart service |
3. **Web application issue** | Error message: "Internal Server Error" | Manyfold not running or configuration incorrect | Check Manyfold logs, restart Manyfold service, verify configuration. | Caddy | Reverse proxy error | Incorrect configuration | Review Caddy configuration file |
--- ---
## Changelog ## Changelog
| Date | Commit | Summary | | Date | Commit | Summary |
|-|-|-| |------|--------|---------|
| 2026-04-28 | a099c463 | Initial deployment of Manyfold stack. | | 2026-04-28 | 04ce338e | Initial documentation creation |
| 2026-04-28 | d0611a95 | Added Postgres and Redis services to the stack. | | 2026-04-28 | a099c463 | Added backup script |
| 2026-04-28 | 7088b84b | Updated environment variables for security. | | 2026-04-28 | d0611a95 | Fixed Caddy configuration issue |
| 2026-04-28 | 7088b84b | Improved service logging |
<Write a paragraph summarizing the evolution of this service based on the diffs above. If no diffs available, note that this is the initial documentation.> <Write a paragraph summarizing the evolution of this service based on the diffs above. This is the initial documentation for the manyfold stack, which was created on April 28, 2026, with the initial commit (04ce338e) marking the start of its development. Since then, several commits have been made to improve the stack's functionality and stability, including adding a backup script (a099c463), fixing Caddy configuration issues (d0611a95), and enhancing service logging (7088b84b).>
This Manyfold stack has undergone significant changes since its initial deployment, with new services such as Postgres and Redis being added to improve data storage and caching capabilities. Additionally, environmental variables have been updated for security purposes.
--- ---
## Notes ## Notes
- Generated by Gremlin on 2026-04-28T20:16:09.403Z - Generated by Gremlin on 2026-04-28T20:42:57.388Z
- Source: swarm/manyfold.yaml - Source: swarm/manyfold.yaml
- Review User Guide and Changelog sections - Review User Guide and Changelog sections