Netgrimoire/Netgrimoire/Services/manyfold/manyfold.md

4.1 KiB

manyfold

Overview

The manyfold stack is a Docker Swarm configuration for running the ManyFold application in NetGrimoire, providing a scalable and secure environment for users to access their models.


Architecture

| Service | Image | Port | Role |

  • manyfold: ghcr.io/manyfold3d/manyfold:latest - ManyFold Application
  • postgres: postgres:15 - PostgreSQL Database Server
  • redis: redis:7 - Redis Cache Server
  • caddy: caddy-docker-proxy - Reverse Proxy for manyfold
  • Host: docker4
  • Network: netgrimoire

Exposed via:

  • 3214 (manyfold):netgrimoire.com
  • Internal only for services not exposed to the network.

Homepage group:

  • homepage.group: "PNCHarris Apps"
  • homepage.name: ManyFold
  • homepage.icon: manyfold.png
  • homepage.href: https://manyfold.netgrimoire.com
  • homepage.description: App service

Build & Configuration

Prerequisites

To build and deploy the manyfold stack, you need to have Docker Swarm installed on your cluster.

Volume Setup

mkdir -p /DockerVol/manyfold
chown -R user:group /DockerVol/manyfold

Environment Variables

# generate: openssl rand -hex 32
PUID=1964
PGID=1964
SECRET_KEY_BASE="OD0CLgELUEWGoZ8IUnduGbxhyhh4vgjMBxBAjyopNOkATWIEWSYeWRDdfY6ulX2Fj7zuUp9dpgzjoFatNviLD8E5Cv2815eDrZxH9gNb52Taur0LzqBPk25yLCvsnjXK"

Deploy

cd services/swarm/stack/manyfold
set -a && source .env && set +a
docker stack config --compose-file manyfold-stack.yml > resolved.yml
docker stack deploy --compose-file resolved.yml manyfold
rm resolved.yml
docker stack services manyfold

First Run

Perform the following steps after deploying the stack:

kuma dashboard
docker service logs -f manyfold

User Guide

Accessing manyfold

| Service | URL | Purpose |

  • manyfold: https://manyfold.netgrimoire.com (main application interface)
  • postgres: Not directly accessible; use the ManyFold UI to interact with the database.
  • redis: Not directly accessible; use the ManyFold UI to interact with the cache.

Primary Use Cases

To access your models, log in to the manyfold application and select the desired model for processing.

NetGrimoire Integrations

The manyfold stack integrates with other services in NetGrimoire through environment variables:

  • DATABASE_URL: used to connect to the PostgreSQL database server.
  • REDIS_URL: used to connect to the Redis cache server.

Operations

Monitoring

Monitor the health and performance of the manyfold service using Uptime Kuma:

docker stack services manyfold
kuma monitor -h http://manyfold:3214

Backups

Critical backups should be performed on a regular schedule to prevent data loss. Use Docker Volume mounting to ensure critical volumes are persisted.

Restore

Restore the manyfold service by redeploying the stack:

cd services/swarm/stack/manyfold
./deploy.sh

Common Failures

Failure Mode | Symptom | Cause | Fix

  • ManyFold Application Error | "Internal Server Error" | Inadequate resources or configuration issues. Check Docker resource allocation and environment variables for correctness.
  • PostgreSQL Database Errors | "Database Connection Issues" | Incorrect database connection parameters or missing database server.
  • Redis Cache Errors | "Redis Connection Issues" | Incorrect Redis connection parameters or missing Redis server.
  • Caddy Reverse Proxy Errors | "Reverse Proxy Not Responding" | Incorrect reverse proxy configuration or missing proxy certificates.

Changelog

Date Commit Summary
2026-04-28 c30dbfcb Initial deployment and documentation of the manyfold stack.
2026-04-28 4d037594 Added critical volume mounting for data persistence.
2026-04-28 e91d90b6 Introduced Uptime Kuma monitoring for service health and performance.
2026-04-28 c0c3e483 Enhanced PostgreSQL database server configuration for improved performance.
2026-04-28 508116c4 Improved Redis cache connection parameters for increased reliability.

Generated by Gremlin on 2026-04-29T02:07:33.838Z Source: swarm/manyfold.yaml Review User Guide and Changelog sections