No description
- Go 96.4%
- Shell 3.6%
|
All checks were successful
release / build-and-release (push) Successful in 1m15s
|
||
|---|---|---|
| .forgejo/workflows | ||
| cmd | ||
| docs | ||
| internal | ||
| packaging/systemd | ||
| scripts | ||
| .gitignore | ||
| config.example.yaml | ||
| go.mod | ||
| go.sum | ||
| LICENSE | ||
| main.go | ||
| README.md | ||
galene-ui
Minimal anonymous web UI for creating Galene groups and redirecting users to the room URL.
Screenshot
Features
- Go backend using Gin.
- CLI and configuration management with Cobra + Viper.
- Configurable via flags, environment variables, or YAML config file.
- HTMX (local static asset, version 2.0.8) for progressive enhancement.
- English and Italian UI pages.
- Creates
<group>.jsonin Galenegroupdirectory with an anonymous-friendly template. - In-memory synchronized group counter.
- Automatic cleanup of empty groups based on Galene
.status.
Build
./scripts/build.sh
Custom output path:
./scripts/build.sh /tmp/galene-ui
Version check:
./dist/galene-ui --version
Run
./dist/galene-ui \
--listen 127.0.0.1:8090 \
--prefix /galene-ui \
--trusted-proxies 127.0.0.1/32,::1/128 \
--galene-public-url https://galene.example.org \
--galene-group-dir /var/lib/galene/groups \
--max-groups 50 \
--max-body-bytes 8192 \
--empty-group-cleanup-timeout 10m \
--cleanup-poll-interval 30s
Reverse Proxy Notes
- Use
prefixwhen serving the app under a sub-path (for example/galene-ui). galene-public-urlis optional for redirects, but required when empty-group cleanup is enabled.galene-ui-public-urlis optional. Default is relative links (works well behind reverse proxy/prefix).- Set
galene-ui-public-urlonly if you explicitly need absolute language links. - Configure
trusted_proxieswith proxy CIDRs or IPs. Default is empty (trust disabled). - Security headers are set directly by the app response.
Cleanup Logic
- Cleanup polls
/group/<name>/.status; ifclientCount == 0continuously forempty-group-cleanup-timeout, the group JSON file is deleted. max-groupsand cleanup apply only to managed groups:"public": true"wildcard-user": { "password": { "type": "wildcard" } }- other keys (including
"permissions") are ignored for detection.
- At startup, if existing managed groups are more than
max-groups, the limit is automatically raised to that count. - Debug endpoint is enabled only when
debug_keyis set and the correct?auth=value is provided.
Routes
With prefix: /galene-ui:
GET /galene-ui/default English UIGET /galene-ui/enEnglish UIGET /galene-ui/itItalian UIPOST /galene-ui/fragments/group/:langHTMX fragment endpointGET /galene-ui/debug/monitored-groups?auth=<debug_key>debug JSON
Environment variables
GALENE_UI_LISTENGALENE_UI_PREFIXGALENE_UI_TRUSTED_PROXIES(comma-separated)GALENE_UI_GALENE_PUBLIC_URLGALENE_UI_GALENE_UI_PUBLIC_URLGALENE_UI_GALENE_GROUP_DIRGALENE_UI_DEBUG_KEYGALENE_UI_MAX_GROUPSGALENE_UI_MAX_BODY_BYTESGALENE_UI_EMPTY_GROUP_CLEANUP_TIMEOUT(for example10m, set0to disable)GALENE_UI_CLEANUP_POLL_INTERVAL(for example30s)GALENE_UI_CONFIG
YAML config
Use --config /path/to/config.yaml or place config.yaml in working directory.
See config.example.yaml.
Release automation
- Forgejo workflow:
.forgejo/workflows/release.yml - Trigger: push of a tag matching
v* - Output: release with
linux-amd64andlinux-arm64binaries - Release notes: generated from semantic commit subjects since the previous tag
License
AGPL-3.0-only. See LICENSE.
