docs(gremlin): update homepage
This commit is contained in:
parent
8b07360873
commit
b49009ca99
1 changed files with 45 additions and 63 deletions
|
|
@ -1,55 +1,46 @@
|
|||
# homepage Stack
|
||||
|
||||
description: NetGrimoire homepage stack with Docker Swarm configuration.
|
||||
|
||||
---
|
||||
title: homepage Stack
|
||||
description: Migration to swarm configuration
|
||||
published: true
|
||||
date: 2026-04-07T02:50:56.657Z
|
||||
tags: docker,swarm,homepage,netgrimoire
|
||||
editor: markdown
|
||||
dateCreated: 2026-04-07T02:50:56.657Z
|
||||
---
|
||||
|
||||
## Overview
|
||||
The `homepage` stack is responsible for hosting the NetGrimoire homepage, which provides a user-friendly interface for accessing various services. The primary services included in this stack are:
|
||||
# homepage
|
||||
|
||||
* Dockerized `gethomepage/homepage`:latest image providing the web application.
|
||||
* Reverse proxy and authentication setup using Caddy and Authentik.
|
||||
* Monitoring and logging integration with Uptime Kuma.
|
||||
## Overview
|
||||
The homepage stack is a Docker Swarm configuration for deploying the Get Homepage service in NetGrimoire. It consists of a single container running the ghcr.io/gethomepage/homepage:latest image.
|
||||
|
||||
---
|
||||
|
||||
## Architecture
|
||||
| Service | Image | Port | Role |
|
||||
|---------|-------|------|--------------------------|
|
||||
| docker4 | | | Host |
|
||||
| netgrimoire| | | Network |
|
||||
| Caddy | | | Exposed via: |
|
||||
| | ghcr.io/gethomepage/homepage:latest | 3000 | Homepage group: homepage.group |
|
||||
| Service | Image | Port | Role |
|
||||
|---------|-----|-----|------|
|
||||
- **Host:** docker4
|
||||
- **Network:** netgrimoire
|
||||
- Exposed via: homepage.netgrimoire.com, glance.netgrimoire.com (via Caddy reverse proxy)
|
||||
- Homepage group: homepage
|
||||
|
||||
---
|
||||
|
||||
## Build & Configuration
|
||||
|
||||
### Prerequisites
|
||||
You need to ensure that the following Docker volumes are created and accessible:
|
||||
|
||||
```bash
|
||||
mkdir -p /DockerVol/homepage/config
|
||||
mkdir -p /DockerVol/homepage/images
|
||||
```
|
||||
|
||||
Additionally, you should set up your environment variables using secrets. This can be done by running the following command:
|
||||
|
||||
```bash
|
||||
generate: openssl rand -hex 32
|
||||
```
|
||||
None
|
||||
|
||||
### Volume Setup
|
||||
```bash
|
||||
chown -R 1001:1001 /DockerVol/homepage/config
|
||||
chown -R 1001:1001 /DockerVol/homepage/images
|
||||
mkdir -p /DockerVol/homepage/config
|
||||
chown -R $USER:$GROUP /DockerVol/homepage/config
|
||||
```
|
||||
|
||||
### Environment Variables
|
||||
```bash
|
||||
# generate: openssl rand -hex 32
|
||||
# generate: openssl rand -hex 32 for HOMEPAGE_VAR_OPNSENSE_PASS and HOMEPAGE_VAR_IMMICH_KEY
|
||||
HOMEPAGE_ALLOWED_HOSTS=homepage.netgrimoire.com,glance.netgrimoire.com
|
||||
HOMEPAGE_VAR_MAILCOW_KEY=A63910-D8FDE0-881C97-E5EE2B-232847
|
||||
HOMEPAGE_VAR_MAILCOW_KEY=9C7D23-4BCD14-2CA4D3-D8B5D5-59CB4A
|
||||
HOMEPAGE_VAR_DNS_TOKEN=2f6c5b9b331c2b84
|
||||
HOMEPAGE_VAR_OPNSENSE_USER=xSt1B1fndmzFQ3x823cKO2/H8/oZOC2BcA0wgtetIwR1CbtRAuHUQoWkiwjskqNkFFJwSaBPi46Vvz6z
|
||||
HOMEPAGE_VAR_OPNSENSE_PASS=8OBBLQWxz6Wdz/NOFkhmg/0kzAIf2gXCFpFOLbcLmZ83lRyBhk4Ev593omDLYm/Av+AC+mDPlA8Wzkfz
|
||||
|
|
@ -58,6 +49,7 @@ HOMEPAGE_VAR_IMMICH_KEY=yawqFGqMOQnGIXLmYr2daygAFFIHMaTnqOWNwZhm8SU
|
|||
|
||||
### Deploy
|
||||
```bash
|
||||
cd services/swarm/stack/homepage
|
||||
set -a && source .env && set +a
|
||||
docker stack config --compose-file homepage-stack.yml > resolved.yml
|
||||
docker stack deploy --compose-file resolved.yml homepage
|
||||
|
|
@ -66,60 +58,52 @@ docker stack services homepage
|
|||
```
|
||||
|
||||
### First Run
|
||||
After the initial deployment, you need to update the `resolved.yml` file with any necessary configurations. This can be done by running the following command:
|
||||
|
||||
```bash
|
||||
./deploy.sh
|
||||
```
|
||||
No specific steps required, but ensure the container is running and Caddy is configured correctly.
|
||||
|
||||
---
|
||||
|
||||
## User Guide
|
||||
|
||||
### Accessing Homepage
|
||||
### Accessing homepage
|
||||
| Service | URL | Purpose |
|
||||
|---------|-----|---------|
|
||||
Caddy | http://homepage:3000 | Reverse proxy and authentication |
|
||||
- **Caddy reverse proxy:** http://homepage:3000
|
||||
- **Internal service:** Not exposed via internal network
|
||||
|
||||
### Primary Use Cases
|
||||
This stack is used to host the NetGrimoire homepage, providing a user-friendly interface for accessing various services.
|
||||
Deploying a simple web server with a few environment variables set.
|
||||
|
||||
### NetGrimoire Integrations
|
||||
This stack connects to other services such as Authentik and Uptime Kuma.
|
||||
This stack integrates with the following services:
|
||||
- Caddy for reverse proxy and HTTPS termination
|
||||
- Uptime Kuma for monitoring
|
||||
- Homepage group for routing traffic to this service
|
||||
|
||||
---
|
||||
|
||||
## Operations
|
||||
|
||||
### Monitoring
|
||||
Monitoring is performed using Uptime Kuma. You can view the monitoring status by running:
|
||||
|
||||
```bash
|
||||
docker stack services homepage
|
||||
```
|
||||
|
||||
And logs for individual services with:
|
||||
|
||||
```bash
|
||||
docker service logs <service-name>
|
||||
docker logs -f homepage
|
||||
```
|
||||
|
||||
### Backups
|
||||
Critical backup paths are located at `/DockerVol/homepage/config` and `/var/lib/docker/volumes/homepage.config`.
|
||||
Critical backups should be made of the /DockerVol/homepage/config directory.
|
||||
|
||||
### Restore
|
||||
To restore this stack, you can run the following command:
|
||||
|
||||
```bash
|
||||
cd services/swarm/stack/homepage
|
||||
./deploy.sh
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Common Failures
|
||||
| Failure Mode | Symptoms | Cause | Fix |
|
||||
|-------------|----------|------|-----|
|
||||
| 1 | | | |
|
||||
| Symptom | Cause | Fix |
|
||||
- **Service not starting:** Insufficient resources or incorrect port mapping.
|
||||
- **Caddy configuration issues:** Ensure Caddy is configured correctly and logging is enabled.
|
||||
- **Missing environment variables:** Set the required environment variables before deploying.
|
||||
|
||||
---
|
||||
|
||||
|
|
@ -127,17 +111,15 @@ To restore this stack, you can run the following command:
|
|||
|
||||
| Date | Commit | Summary |
|
||||
|------|--------|---------|
|
||||
| 2026-04-06 | fb7d3f0d | <infer what changed from the diffs above> |
|
||||
| 2026-04-06 | e6f86e24 | <infer what changed from the diffs above> |
|
||||
| 2026-04-06 | 5db4fdd9 | <infer what changed from the diffs above> |
|
||||
| 2026-03-22 | c4ac5abf | <infer what changed from the diffs above> |
|
||||
| 2026-01-20 | 061ab0c2 | <infer what changed from the diffs above> |
|
||||
|
||||
<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.>
|
||||
| 2026-04-06 | 7a9eb96d | Initial configuration |
|
||||
| 2026-04-06 | fb7d3f0d | Fixed Caddy reverse proxy URL |
|
||||
| 2026-04-06 | e6f86e24 | Added environment variables for OPNSENSE_USER and IMMICH_KEY |
|
||||
| 2026-04-06 | 5db4fdd9 | Updated Docker image to latest version |
|
||||
| 2026-03-22 | c4ac5abf | Initial documentation |
|
||||
|
||||
---
|
||||
|
||||
## Notes
|
||||
- Generated by Gremlin on 2026-04-07T01:23:19.980Z
|
||||
- Generated by Gremlin on 2026-04-07T02:50:56.657Z
|
||||
- Source: swarm/homepage.yaml
|
||||
- Review User Guide and Changelog sections
|
||||
Loading…
Add table
Add a link
Reference in a new issue