feat: implement single binary build and env-based auth
- Unify login page styling with share page - Add AGENTS.md with build commands and code style guidelines - Add dev.sh and make.sh for development and production builds - Implement single binary build with embedded frontend using embed.FS - Change auth configuration from CLI flag to env variables (USHARE_USERNAME, USHARE_PASSWORD) - Set default credentials: admin / ushare@123 - Fix static file serving for SPA routes
This commit is contained in:
14
internal/static/static.go
Normal file
14
internal/static/static.go
Normal file
@@ -0,0 +1,14 @@
|
||||
package static
|
||||
|
||||
import (
|
||||
"embed"
|
||||
"io/fs"
|
||||
)
|
||||
|
||||
//go:embed frontend/dist
|
||||
var FrontendFS embed.FS
|
||||
|
||||
func Frontend() fs.FS {
|
||||
sub, _ := fs.Sub(FrontendFS, "frontend/dist")
|
||||
return sub
|
||||
}
|
||||
Reference in New Issue
Block a user