- Created caddyfile-docs-update.txt with Caddy basic auth configuration - Fixed documentation path from /home/klas/langmem-docs to /home/klas/langmem/docs - Added basic auth with credentials: langmem / langmem2025 - Created create-claude-matrix-user.md with user creation instructions - Added get-claude-token.py script for automated Matrix setup - Includes token retrieval, room joining, and configuration export Manual steps required: 1. Update /etc/caddy/Caddyfile with new docs.klas.chat config 2. Reload Caddy: sudo systemctl reload caddy 3. Create Claude Matrix user via admin panel 4. Run get-claude-token.py to complete setup 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
40 lines
1.2 KiB
Plaintext
40 lines
1.2 KiB
Plaintext
# Updated docs.klas.chat configuration with authentication
|
|
# Replace the existing docs.klas.chat block in /etc/caddy/Caddyfile with this:
|
|
|
|
docs.klas.chat {
|
|
tls /certs/klas.chat/fullchain.cer /certs/klas.chat/klas.chat.key
|
|
|
|
# Basic Authentication
|
|
basicauth * {
|
|
langmem $2a$14$.1fx02QwkkmfezhZMLE4Iu2N/ub5vwDSAtcH9lAa5z11ChjiYy1PG
|
|
}
|
|
|
|
# Security headers
|
|
header {
|
|
X-Frame-Options "DENY"
|
|
X-Content-Type-Options "nosniff"
|
|
X-XSS-Protection "1; mode=block"
|
|
Referrer-Policy "strict-origin-when-cross-origin"
|
|
Strict-Transport-Security "max-age=31536000; includeSubDomains"
|
|
Content-Security-Policy "default-src 'self'; script-src 'self' 'unsafe-inline' https://cdn.jsdelivr.net; style-src 'self' 'unsafe-inline' https://cdn.jsdelivr.net; img-src 'self' data: https:; font-src 'self' data:;"
|
|
}
|
|
|
|
# Static file serving - UPDATED PATH
|
|
root * /home/klas/langmem/docs
|
|
file_server
|
|
|
|
# SPA routing fallback for clean URLs
|
|
try_files {path} {path}/ /index.html
|
|
|
|
# Enable compression
|
|
encode gzip
|
|
|
|
# Cache static assets
|
|
@static {
|
|
path *.css *.js *.png *.jpg *.jpeg *.gif *.svg *.ico *.woff *.woff2
|
|
}
|
|
|
|
header @static Cache-Control "public, max-age=31536000, immutable"
|
|
}
|
|
|
|
# Credentials: langmem / langmem2025 |