mirror of
				https://github.com/community-scripts/ProxmoxVE.git
				synced 2025-11-04 10:22:50 +00:00 
			
		
		
		
	Reactive Resume: use new release parsing; other fixes (#6744)
This commit is contained in:
		@@ -8,7 +8,7 @@ source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxV
 | 
			
		||||
APP="Reactive-Resume"
 | 
			
		||||
var_tags="${var_tags:-documents}"
 | 
			
		||||
var_cpu="${var_cpu:-2}"
 | 
			
		||||
var_ram="${var_ram:-3072}"
 | 
			
		||||
var_ram="${var_ram:-4096}"
 | 
			
		||||
var_disk="${var_disk:-8}"
 | 
			
		||||
var_os="${var_os:-debian}"
 | 
			
		||||
var_version="${var_version:-12}"
 | 
			
		||||
@@ -28,15 +28,16 @@ function update_script() {
 | 
			
		||||
    msg_error "No $APP Installation Found!"
 | 
			
		||||
    exit
 | 
			
		||||
  fi
 | 
			
		||||
  RELEASE=$(curl -fsSL https://api.github.com/repos/lazy-media/Reactive-Resume/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
 | 
			
		||||
  RELEASE=$(curl -fsSL https://api.github.com/repos/lazy-media/Reactive-Resume/releases/latest | jq -r '.tag_name' | sed 's/^v//')
 | 
			
		||||
  if [[ ! -f "$HOME"/.reactive-resume ]] || [[ "$RELEASE" != "$(cat "$HOME"/.reactive-resume)" ]]; then
 | 
			
		||||
    msg_info "Stopping services"
 | 
			
		||||
    systemctl stop Reactive-Resume
 | 
			
		||||
    msg_ok "Stopped services"
 | 
			
		||||
 | 
			
		||||
    cp /opt/"$APP"/.env /opt/rxresume.env
 | 
			
		||||
    rm -rf /opt/"$APP"
 | 
			
		||||
    fetch_and_deploy_gh_release "Reactive-Resume" "lazy-media/Reactive-Resume"
 | 
			
		||||
 | 
			
		||||
    fetch_and_deploy_gh_release "Reactive-Resume" "lazy-media/Reactive-Resume" "tarball" "latest" "/opt/Reactive-Resume"
 | 
			
		||||
 | 
			
		||||
    msg_info "Updating $APP to v${RELEASE}"
 | 
			
		||||
    cd /opt/"$APP"
 | 
			
		||||
    export PUPPETEER_SKIP_DOWNLOAD="true"
 | 
			
		||||
@@ -84,9 +85,9 @@ function update_script() {
 | 
			
		||||
    rm -f "$brwsr_tmp"
 | 
			
		||||
    msg_ok "Cleanup Completed"
 | 
			
		||||
 | 
			
		||||
    msg_ok "Update Successful"
 | 
			
		||||
    msg_ok "Updated Successfully"
 | 
			
		||||
  else
 | 
			
		||||
    msg_ok "No update required. $APP is already at v{$RELEASE}"
 | 
			
		||||
    msg_ok "No update required. $APP is already at v${RELEASE}"
 | 
			
		||||
  fi
 | 
			
		||||
  exit
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
@@ -20,7 +20,7 @@
 | 
			
		||||
      "script": "ct/reactive-resume.sh",
 | 
			
		||||
      "resources": {
 | 
			
		||||
        "cpu": 2,
 | 
			
		||||
        "ram": 3072,
 | 
			
		||||
        "ram": 4096,
 | 
			
		||||
        "hdd": 8,
 | 
			
		||||
        "os": "Debian",
 | 
			
		||||
        "version": "12"
 | 
			
		||||
 
 | 
			
		||||
@@ -19,7 +19,7 @@ curl -fsSL https://dl.min.io/server/minio/release/linux-amd64/minio.deb -o minio
 | 
			
		||||
$STD dpkg -i minio.deb
 | 
			
		||||
msg_ok "Installed Dependencies"
 | 
			
		||||
 | 
			
		||||
PG_VERSION="16" PG_MODULES="common" setup_postgresql
 | 
			
		||||
PG_VERSION="16" setup_postgresql
 | 
			
		||||
NODE_VERSION="22" NODE_MODULE="pnpm@latest" setup_nodejs
 | 
			
		||||
 | 
			
		||||
msg_info "Setting up Database"
 | 
			
		||||
@@ -32,7 +32,6 @@ $STD sudo -u postgres psql -c "GRANT ALL PRIVILEGES ON DATABASE $DB_NAME to $DB_
 | 
			
		||||
$STD sudo -u postgres psql -c "ALTER USER $DB_USER WITH SUPERUSER;"
 | 
			
		||||
msg_ok "Set up Database"
 | 
			
		||||
 | 
			
		||||
msg_info "Installing $APPLICATION"
 | 
			
		||||
MINIO_PASS=$(openssl rand -base64 48)
 | 
			
		||||
ACCESS_TOKEN=$(openssl rand -base64 48)
 | 
			
		||||
REFRESH_TOKEN=$(openssl rand -base64 48)
 | 
			
		||||
@@ -41,6 +40,8 @@ LOCAL_IP=$(hostname -I | awk '{print $1}')
 | 
			
		||||
TAG=$(curl -fsSL https://api.github.com/repos/browserless/browserless/tags?per_page=1 | grep "name" | awk '{print substr($2, 3, length($2)-4) }')
 | 
			
		||||
 | 
			
		||||
fetch_and_deploy_gh_release "Reactive-Resume" "lazy-media/Reactive-Resume"
 | 
			
		||||
 | 
			
		||||
msg_info "Installing $APPLICATION"
 | 
			
		||||
cd /opt/"$APPLICATION"
 | 
			
		||||
export CI="true"
 | 
			
		||||
export PUPPETEER_SKIP_DOWNLOAD="true"
 | 
			
		||||
@@ -48,7 +49,6 @@ export NODE_ENV="production"
 | 
			
		||||
export NEXT_TELEMETRY_DISABLED=1
 | 
			
		||||
$STD pnpm install --frozen-lockfile
 | 
			
		||||
$STD pnpm run build
 | 
			
		||||
$STD pnpm install --prod --frozen-lockfile
 | 
			
		||||
$STD pnpm run prisma:generate
 | 
			
		||||
msg_ok "Installed $APPLICATION"
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user