use GODEBUG=embedfollowsymlinks=1 to support symlinked web src files
This commit is contained in:
1 parent
98790dbe3b
commit
5c658db34e
94 files changed
+11
-14
No files matched your search
@@ -1,9 +1,12 @@
|
|||||||
.PHONY: build build-web build-wfa clean clean-wfa clean-web
|
.PHONY: test build build-wfa clean clean-wfa clean-web
|
||||||
|
|
||||||
build: clean ensure-dist build-wfa build-web
|
build: clean ensure-dist build-wfa
|
||||||
@echo "======================== Building Binary ======================="
|
@echo "======================== Building Binary ======================="
|
||||||
# resolve symbolic links in web by copying it into dist/web/
|
# resolve symbolic links in web by copying it into dist/web/
|
||||||
CGO_ENABLED=0 go build -tags release -ldflags="-s -w" -v -o dist/ .
|
GODEBUG=embedfollowsymlinks=1 CGO_ENABLED=0 go build -tags release -ldflags="-s -w" -v -o dist/ .
|
||||||
|
|
||||||
|
test:
|
||||||
|
GODEBUG=embedfollowsymlinks=1 CGO_ENABLED=0 go run .
|
||||||
|
|
||||||
clean: clean-wfa clean-web
|
clean: clean-wfa clean-web
|
||||||
@echo "======================== Cleaning Project ======================"
|
@echo "======================== Cleaning Project ======================"
|
||||||
@@ -13,14 +16,11 @@ clean: clean-wfa clean-web
|
|||||||
ensure-dist:
|
ensure-dist:
|
||||||
mkdir -p dist
|
mkdir -p dist
|
||||||
|
|
||||||
build-web: ensure-dist
|
|
||||||
cp -rL web/ dist/web/
|
|
||||||
|
|
||||||
clean-web:
|
clean-web:
|
||||||
|
|
||||||
build-wfa:
|
build-wfa:
|
||||||
$(MAKE) -C WFA-JS
|
$(MAKE) -C WFA-JS
|
||||||
cp -f WFA-JS/dist/* web/modules
|
cp -f WFA-JS/dist/* app/web/modules
|
||||||
|
|
||||||
clean-wfa:
|
clean-wfa:
|
||||||
$(MAKE) clean -C WFA-JS
|
$(MAKE) clean -C WFA-JS
|
||||||
+3
-1
@@ -7,7 +7,9 @@ import (
|
|||||||
"net/http"
|
"net/http"
|
||||||
"proxmoxaas-dashboard/app/common"
|
"proxmoxaas-dashboard/app/common"
|
||||||
"proxmoxaas-dashboard/app/routes"
|
"proxmoxaas-dashboard/app/routes"
|
||||||
"web" // go will complain here until the first build
|
"proxmoxaas-dashboard/app/web"
|
||||||
|
|
||||||
|
//"web" // go will complain here until the first build
|
||||||
|
|
||||||
"github.com/tdewolff/minify/v2"
|
"github.com/tdewolff/minify/v2"
|
||||||
)
|
)
|
||||||
|
|||||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -6,6 +6,7 @@ import (
|
|||||||
|
|
||||||
//go:embed css/*
|
//go:embed css/*
|
||||||
//go:embed images/*
|
//go:embed images/*
|
||||||
|
//go:embed images/*/*/*
|
||||||
//go:embed modules/*
|
//go:embed modules/*
|
||||||
//go:embed scripts/*
|
//go:embed scripts/*
|
||||||
var Static embed.FS
|
var Static embed.FS
|
||||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -7,11 +7,8 @@ require (
|
|||||||
github.com/go-viper/mapstructure/v2 v2.5.0
|
github.com/go-viper/mapstructure/v2 v2.5.0
|
||||||
github.com/tdewolff/minify/v2 v2.24.17
|
github.com/tdewolff/minify/v2 v2.24.17
|
||||||
proxmoxaas-common-lib v0.0.0
|
proxmoxaas-common-lib v0.0.0
|
||||||
web v0.0.0
|
|
||||||
)
|
)
|
||||||
|
|
||||||
replace proxmoxaas-common-lib => ./proxmoxaas-common-lib
|
replace proxmoxaas-common-lib => ./proxmoxaas-common-lib
|
||||||
|
|
||||||
replace web => ./dist/web
|
|
||||||
|
|
||||||
require github.com/tdewolff/parse/v2 v2.8.16 // indirect
|
require github.com/tdewolff/parse/v2 v2.8.16 // indirect
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
module web
|
|
||||||
|
|
||||||
go 1.26.0
|
|
||||||
Reference in new issue
Block a user