diff --git a/Makefile b/Makefile index 053018109..5f43598c8 100644 --- a/Makefile +++ b/Makefile @@ -22,7 +22,7 @@ BUILD_ARCH ?= $(shell scripts/dist/arch.sh) JS_BUILD_PATH ?= $(shell realpath "./assets/static/build") # Install parameters. -INSTALL_PATH ?= $(BUILD_PATH)/photoprism-ce-$(BUILD_TAG)-$(shell echo $(BUILD_OS) | tr '[:upper:]' '[:lower:]')-$(BUILD_ARCH) +INSTALL_PATH ?= $(BUILD_PATH)/photoprism-ce_$(BUILD_TAG)-$(shell echo $(BUILD_OS) | tr '[:upper:]' '[:lower:]')-$(BUILD_ARCH) DESTDIR ?= $(INSTALL_PATH) DESTUID ?= 1000 DESTGID ?= 1000 @@ -120,12 +120,11 @@ install: mkdir --mode=$(INSTALL_MODE) -p $(DESTDIR) env TMPDIR="$(BUILD_PATH)" ./scripts/dist/install-tensorflow.sh $(DESTDIR) rm -rf --preserve-root $(DESTDIR)/include - (cd $(DESTDIR) && mkdir -p bin lib assets config config/examples) + (cd $(DESTDIR) && mkdir -p bin lib assets) ./scripts/build.sh prod "$(DESTDIR)/bin/$(BINARY_NAME)" rsync -r -l --safe-links --exclude-from=assets/.buildignore --chmod=a+r,u+rw ./assets/ $(DESTDIR)/assets wget -O $(DESTDIR)/assets/static/img/wallpaper/welcome.jpg https://cdn.photoprism.app/wallpaper/welcome.jpg wget -O $(DESTDIR)/assets/static/img/preview.jpg https://cdn.photoprism.app/img/preview.jpg - cp internal/config/testdata/*.yml $(DESTDIR)/config/examples chown -R $(INSTALL_USER) $(DESTDIR) chmod -R $(INSTALL_MODE) $(DESTDIR) chmod -R $(INSTALL_MODE_BIN) $(DESTDIR)/bin $(DESTDIR)/lib diff --git a/scripts/dist/install-go-tools.sh b/scripts/dist/install-go-tools.sh index cc61fbd3c..9264f73a5 100755 --- a/scripts/dist/install-go-tools.sh +++ b/scripts/dist/install-go-tools.sh @@ -32,8 +32,6 @@ elif [[ -z $GOPATH ]]; then GOPATH=$(go env GOPATH) fi -echo "Installing Go tools for ${DESTARCH^^} in $GOPATH..." - set -e mkdir -p "$GOPATH/src" @@ -46,13 +44,14 @@ case $DESTARCH in ;; *) - echo "Installing Go tools in /usr/local/bin..." + echo "Installing Go tools for ${DESTARCH^^} in /usr/local/bin..." GOBIN="/usr/local/bin" go install golang.org/x/tools/cmd/goimports@latest GOBIN="/usr/local/bin" go install github.com/psampaz/go-mod-outdated@latest GOBIN="/usr/local/bin" go install github.com/mikefarah/yq/v4@latest GOBIN="/usr/local/bin" go install github.com/kyoh86/richgo@latest GOBIN="/usr/local/bin" go install github.com/muesli/duf@latest GOBIN="/usr/local/bin" go install github.com/go-delve/delve/cmd/dlv@latest + GOBIN="/usr/local/bin" go install github.com/goreleaser/nfpm/v2/cmd/nfpm@latest ;; esac