mirror of
https://github.com/selfhosters-cc/container-census.git
synced 2026-05-24 08:18:45 -05:00
96b6cc1fb6
This commit replaces the browser's native Basic Auth prompt with a custom login page to improve user experience and avoid browser credential caching issues. Authentication Changes: - Add gorilla/sessions for cookie-based session management - Create login page with instructions for finding credentials - Add logout button (🚪 icon) to navbar - Root path (/) now redirects to /login.html when unauthenticated - Maintain backward compatibility with Basic Auth for API clients - Add SESSION_SECRET environment variable for session encryption Implementation: - internal/auth/session.go: Session middleware and management - internal/api/auth_handlers.go: Login/logout HTTP endpoints - internal/api/handlers.go: Updated routing with selective auth - cmd/server/main.go: Session store initialization - web/login.html: Login page with credential finding instructions - web/login.js: Login form handling - web/app.js: 401 redirect handling and logout function - web/index.html: Logout button in navbar Documentation: - README.md: Added SESSION_SECRET to docker-compose example - README.md: Added "Authentication Issues" troubleshooting section - scripts/run-local.sh: Added auth prompt with qwerty credentials Onboarding Tour: - Restored "Join the Selfhosting Community" telemetry opt-in step - Added updateTelemetrySettings() method - Tour now has 5 steps including community contribution option 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
52 lines
2.1 KiB
Modula-2
52 lines
2.1 KiB
Modula-2
module github.com/container-census/container-census
|
|
|
|
go 1.25
|
|
|
|
require (
|
|
github.com/docker/docker v28.3.3+incompatible
|
|
github.com/google/uuid v1.6.0
|
|
github.com/gorilla/mux v1.8.1
|
|
github.com/lib/pq v1.10.9
|
|
github.com/mattn/go-sqlite3 v1.14.24
|
|
gopkg.in/yaml.v3 v3.0.1
|
|
)
|
|
|
|
require (
|
|
github.com/Microsoft/go-winio v0.6.2 // indirect
|
|
github.com/containerd/errdefs v1.0.0 // indirect
|
|
github.com/containerd/errdefs/pkg v0.3.0 // indirect
|
|
github.com/containerd/log v0.1.0 // indirect
|
|
github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect
|
|
github.com/distribution/reference v0.6.0 // indirect
|
|
github.com/docker/go-connections v0.6.0 // indirect
|
|
github.com/docker/go-units v0.5.0 // indirect
|
|
github.com/felixge/httpsnoop v1.0.4 // indirect
|
|
github.com/go-logr/logr v1.4.3 // indirect
|
|
github.com/go-logr/stdr v1.2.2 // indirect
|
|
github.com/gogo/protobuf v1.3.2 // indirect
|
|
github.com/gorilla/securecookie v1.1.2 // indirect
|
|
github.com/gorilla/sessions v1.4.0 // indirect
|
|
github.com/moby/docker-image-spec v1.3.1 // indirect
|
|
github.com/moby/sys/atomicwriter v0.1.0 // indirect
|
|
github.com/moby/term v0.5.2 // indirect
|
|
github.com/morikuni/aec v1.0.0 // indirect
|
|
github.com/opencontainers/go-digest v1.0.0 // indirect
|
|
github.com/opencontainers/image-spec v1.1.1 // indirect
|
|
github.com/pkg/errors v0.9.1 // indirect
|
|
github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect
|
|
github.com/rogpeppe/go-internal v1.14.1 // indirect
|
|
go.opentelemetry.io/auto/sdk v1.1.0 // indirect
|
|
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.62.0 // indirect
|
|
go.opentelemetry.io/otel v1.38.0 // indirect
|
|
go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.38.0 // indirect
|
|
go.opentelemetry.io/otel/metric v1.38.0 // indirect
|
|
go.opentelemetry.io/otel/sdk v1.38.0 // indirect
|
|
go.opentelemetry.io/otel/sdk/metric v1.38.0 // indirect
|
|
go.opentelemetry.io/otel/trace v1.38.0 // indirect
|
|
golang.org/x/net v0.44.0 // indirect
|
|
golang.org/x/sys v0.36.0 // indirect
|
|
golang.org/x/time v0.14.0 // indirect
|
|
google.golang.org/protobuf v1.36.9 // indirect
|
|
gotest.tools/v3 v3.5.2 // indirect
|
|
)
|