docs(gremlin): update homepage

This commit is contained in:
traveler 2026-04-30 09:59:33 -05:00
parent bda85b63ad
commit 7f31cf4026

View file

@ -1,49 +1,42 @@
# homepage Stack # homepage Stack
description: Migration to swarm configuration description: NetGrimoire Homepage service
--- ---
# homepage title: homepage Stack
## Overview ## Overview
This stack is responsible for deploying the homepage service in NetGrimoire, providing a central hub for users to access various tools and resources. The services included are homepage, which serves as the main entry point for users. The `homepage` stack provides a web interface for accessing the NetGrimoire dashboard. The stack consists of a single service, which is deployed on the `znas` node.
---
## Architecture ## Architecture
| Service | Image | Port | Role | | Service | Image | Port | Role |
|- **Host:** docker4 |---------|-------|------|------|
- **Host:** docker4
- **Network:** netgrimoire - **Network:** netgrimoire
- **Exposed via:** homepage.netgrimoire.com,glance.netgrimoire.com - Exposed via: `homepage.netgrimoire.com`
- **Homepage group:** homepage - **Homepage group:** homepage
--- ---
title: Build & Configuration
## Build & Configuration
### Prerequisites ### Prerequisites
``` Ensure that the `.env` file is present and sourced in the deploy script.
mkdir -p /DockerVol/homepage
chown -R user:group /DockerVol/homepage
```
### Volume Setup ### Volume Setup
```bash ```bash
# Make sure your local config directory exists
mkdir -p /DockerVol/homepage/config mkdir -p /DockerVol/homepage/config
# Copy the config file to the container chown -R nobody:nobody /DockerVol/homepage/config
cp /path/to/local/config/file /DockerVol/homepage/config/
``` ```
### Environment Variables ### Environment Variables
```bash ```bash
# generate: openssl rand -hex 32 for secrets # generate: openssl rand -hex 32
HOMEPAGE_ALLOWED_HOSTS: homepage.netgrimoire.com,glance.netgrimoire.com,homepage:3000,192.168.5.10:3056 HOMEPAGE_ALLOWED_HOSTS: homepage.netgrimoire.com,glance.netgrimoire.com,homepage:3000,192.168.5.10:3056
HOMEPAGE_VAR_MAILCOW_KEY: <32-character random string> HOMEPAGE_VAR_MAILCOW_KEY: 9C7D23-4BCD14-2CA4D3-D8B5D5-59CB4A
HOMEPAGE_VAR_DNS_TOKEN: <16-character random string> HOMEPAGE_VAR_DNS_TOKEN: 2f6c5b9b331c2b84
HOMEPAGE_VAR_OPNSENSE_USER: <16-character random string> HOMEPAGE_VAR_OPNSENSE_USER: xSt1B1fndmzFQ3x823cKO2/H8/oZOC2BcA0wgtetIwR1CbtRAuHUQoWkiwjskqNkFFJwSaBPi46Vvz6z
HOMEPAGE_VAR_OPNSENSE_PASS: <16-character random string> HOMEPAGE_VAR_OPNSENSE_PASS: 8OBBLQWxz6Wdz/NOFkhmg/0kzAIf2gXCFpFOLbcLmZ83lRyBhk4Ev593omDLYm/Av+AC+mDPlA8Wzkfz
HOMEPAGE_VAR_IMMICH_KEY: <16-character random string> HOMEPAGE_VAR_IMMICH_KEY: yawqFGqMOQnGIXLmYr2daygAFFIHMaTnqOWNwZhm8SU
``` ```
### Deploy ### Deploy
@ -56,72 +49,62 @@ rm resolved.yml
docker stack services homepage docker stack services homepage
``` ```
### First Run ---
After the initial deployment, ensure that all necessary services are running and the configuration is complete. title: First Run
Perform the following steps after deploying the service:
```bash
# Initialize database and load data
npm run init db
npm run load-data
```
--- ---
title: User Guide
## User Guide ### Accessing Homepage
### Accessing homepage
| Service | URL | Purpose | | Service | URL | Purpose |
|- **Host:** docker4 - **Host:** `homepage.netgrimoire.com`
- **URL:** http://homepage:3000 - **Port:** `3000` or `3056` (via reverse proxy)
- **Purpose:** Access the homepage interface
### Primary Use Cases ### Primary Use Cases
The primary use case for this stack is to provide a centralized hub for users to access various tools and resources. Access the NetGrimoire dashboard to view and manage services, settings, and data.
### NetGrimoire Integrations ### NetGrimoire Integrations
This stack connects to other services in NetGrimoire, such as authentik and crowdsec. The `homepage` stack integrates with other services in the NetGrimoire network via environment variables and labels.
--- ---
title: Operations
## Operations
### Monitoring ### Monitoring
[kuma monitors from kuma.* labels]
```bash ```bash
docker stack services homepage docker stack services homepage
docker service logs -f homepage kuma logs -f
``` ```
### Backups ### Backups
Critical backups are required for critical data stored on /DockerVol/homepage/. This directory should be backed up regularly. Critical data is stored on the `/DockerVol/homepage/data` mount point. This directory should be backed up regularly to prevent data loss.
### Restore ### Restore
Restore the container by running `./deploy.sh`. ```bash
cd services/swarm/stack/homepage
./deploy.sh
```
--- ---
title: Common Failures
## Common Failures | Symptom | Cause | Fix |
| Failure Mode | Symptom | Cause | Fix | |---------|-------|-----|
|- **Failure Mode 1:** Docker Service Not Running - Service not responding
| **Symptom:** "Service <service-name> does not exist" - Cause: Container is not running or has crashed.
| **Cause:** The service is not deployed. - Fix: Check container logs and restart the service if necessary.
| **Fix:** Run `docker stack deploy --compose-file resolved.yml homepage` to redeploy the service.
|- **Failure Mode 2:** Network Connection Issues - Reverse proxy issues
| **Symptom:** Cannot access the URL or connect to the network. - Cause: Caddy configuration is incorrect.
| **Cause:** There are issues with the network configuration. - Fix: Review Caddy configuration files and update as needed.
| **Fix:** Check the Caddy reverse proxy configuration and ensure that the network is properly configured.
--- - Data corruption
- Cause: Database or file system issues.
## Changelog - Fix: Run database and file system checks to identify and correct any errors.
| Date | Commit | Summary |
|- 2026-04-30 | e76c8767 | Initial deployment of homepage stack
|- 2026-04-30 | 087eb3e5 | Fixed issue with environment variable generation
|- 2026-04-30 | 3588b97a | Improved backup configuration
|- 2026-04-30 | 94a1f0d9 | Enhanced security measures for sensitive data
|- 2026-04-30 | f6f954c9 | Resolved issues with Docker service logs
| 2026-04-27 | 0b974044 | Updated Caddy reverse proxy configuration
| 2026-04-27 | 340b5fcf | Improved monitoring configuration
| 2026-04-27 | bb59fec1 | Fixed issue with sensitive data storage
---
## Notes
Generated by Gremlin on 2026-04-30T14:55:01.161Z
Source: swarm/homepage.yaml
Review User Guide and Changelog sections