Update photoprism.sh

Transitioned to PhotoPrism's latest installation package, featuring Linux binaries.
This commit is contained in:
tteckster 2023-11-02 10:45:28 -04:00 committed by GitHub
parent 19a6a06f5f
commit 8982211e12
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -20,8 +20,8 @@ header_info
echo -e "Loading..." echo -e "Loading..."
APP="PhotoPrism" APP="PhotoPrism"
var_disk="8" var_disk="8"
var_cpu="4" var_cpu="2"
var_ram="4096" var_ram="2048"
var_os="debian" var_os="debian"
var_version="12" var_version="12"
variables variables
@ -61,24 +61,9 @@ function update_script() {
sudo systemctl stop photoprism sudo systemctl stop photoprism
msg_ok "Stopped PhotoPrism" msg_ok "Stopped PhotoPrism"
msg_info "Cloning PhotoPrism" msg_info "Updating PhotoPrism"
cd ~ wget -q -cO - https://dl.photoprism.app/pkg/linux/amd64.tar.gz | tar -xzf - -C /opt/photoprism --strip-components=1
git clone https://github.com/photoprism/photoprism.git &>/dev/null msg_ok "Updated PhotoPrism"
cd photoprism
git checkout release &>/dev/null
msg_ok "Cloned PhotoPrism"
msg_info "Building PhotoPrism"
sudo make all &>/dev/null
sudo ./scripts/build.sh prod /opt/photoprism/bin/photoprism &>/dev/null
sudo rm -rf /opt/photoprism/assets
sudo cp -r assets/ /opt/photoprism/ &>/dev/null
msg_ok "Built PhotoPrism"
msg_info "Cleaning"
cd ~
rm -rf photoprism
msg_ok "Cleaned"
msg_info "Starting PhotoPrism" msg_info "Starting PhotoPrism"
sudo systemctl start photoprism sudo systemctl start photoprism
@ -91,9 +76,6 @@ start
build_container build_container
description description
msg_info "Setting Container to Normal Resources"
pct set $CTID -memory 2048
msg_ok "Set Container to Normal Resources"
msg_ok "Completed Successfully!\n" msg_ok "Completed Successfully!\n"
echo -e "${APP} should be reachable by going to the following URL. echo -e "${APP} should be reachable by going to the following URL.
${BL}http://${IP}:2342${CL} \n" ${BL}http://${IP}:2342${CL} \n"