mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-06-29 02:27:37 +00:00
Update Hoarder: Improvement .env location (see PR comment for little migration) (#1325)
* Update .env file location in hoarder-install.sh * Update .env file location in hoarder.sh No more need to move around the .env file * migration of .env to hoarder.env in hoarder.sh * Update ct/hoarder.sh Co-authored-by: Mohamed Bassem <me@mbassem.com> --------- Co-authored-by: CanbiZ <47820557+MickLesk@users.noreply.github.com> Co-authored-by: Mohamed Bassem <me@mbassem.com>
This commit is contained in:
@ -40,7 +40,10 @@ function update_script() {
|
||||
msg_ok "Stopped Services"
|
||||
msg_info "Updating ${APP} to v${RELEASE}"
|
||||
cd /opt
|
||||
mv /opt/hoarder/.env /opt/.env
|
||||
if [[ -f /opt/hoarder/.env ]] && [[ ! -f /etc/hoarder/hoarder.env ]]; then
|
||||
mkdir -p /etc/hoarder
|
||||
mv /opt/hoarder/.env /etc/hoarder/hoarder.env
|
||||
fi
|
||||
rm -rf /opt/hoarder
|
||||
wget -q "https://github.com/hoarder-app/hoarder/archive/refs/tags/v${RELEASE}.zip"
|
||||
unzip -q v${RELEASE}.zip
|
||||
@ -54,8 +57,7 @@ function update_script() {
|
||||
export DATA_DIR=/opt/hoarder_data
|
||||
cd /opt/hoarder/packages/db
|
||||
pnpm migrate &>/dev/null
|
||||
mv /opt/.env /opt/hoarder/.env
|
||||
sed -i "s/SERVER_VERSION=${PREV_RELEASE}/SERVER_VERSION=${RELEASE}/" /opt/hoarder/.env
|
||||
sed -i "s/SERVER_VERSION=${PREV_RELEASE}/SERVER_VERSION=${RELEASE}/" /etc/hoarder/hoarder.env
|
||||
msg_ok "Updated ${APP} to v${RELEASE}"
|
||||
|
||||
msg_info "Starting Services"
|
||||
@ -79,4 +81,4 @@ description
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW} Access it using the following URL:${CL}"
|
||||
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:3000${CL}"
|
||||
echo -e "${TAB}${GATEWAY}${BGN}http://${IP}:3000${CL}"
|
||||
|
Reference in New Issue
Block a user