From d8f9e4723a8ecb2fa6f4d2aa519ae4d7664b0ea6 Mon Sep 17 00:00:00 2001 From: Wolfdragon24 Date: Tue, 9 Jul 2024 20:20:46 +1000 Subject: [PATCH] Update to puppeteer version --- Dockerfile | 6 ------ commands/courseRating.js | 2 -- package-lock.json | 2 +- package.json | 2 +- 4 files changed, 2 insertions(+), 10 deletions(-) diff --git a/Dockerfile b/Dockerfile index a84316fe..50789102 100644 --- a/Dockerfile +++ b/Dockerfile @@ -5,12 +5,6 @@ ENV NODE_ENV=production # Set working directory WORKDIR /app -# We don't need the standalone Chromium -ENV PUPPETEER_SKIP_DOWNLOAD true - -# Install Chromium manually -RUN apk add --no-cache \ chromium - # Install dependencies COPY package.json package-lock.json ./ RUN npm ci --omit=dev diff --git a/commands/courseRating.js b/commands/courseRating.js index c5ce1cec..c2fcf792 100644 --- a/commands/courseRating.js +++ b/commands/courseRating.js @@ -9,8 +9,6 @@ const puppeteer = require("puppeteer"); async function extractRating(url) { const browser = await puppeteer.launch({ headless: true, - args: ["--no-sandbox", "--disable-setuid-sandbox"], - executablePath: "/usr/bin/chromium", }); const page = await browser.newPage(); diff --git a/package-lock.json b/package-lock.json index c38ee357..870c269a 100644 --- a/package-lock.json +++ b/package-lock.json @@ -30,7 +30,7 @@ "nodemailer": "6.9.13", "nodemon": "^3.0.0", "pg": "8.12.0", - "puppeteer": "^22.11.0", + "puppeteer": "^22.12.1", "textversionjs": "1.1.3", "voucher-code-generator": "1.3.0", "xkcd-api": "^1.0.1", diff --git a/package.json b/package.json index 43acfd9d..ead7aa0d 100644 --- a/package.json +++ b/package.json @@ -45,7 +45,7 @@ "nodemailer": "6.9.13", "nodemon": "^3.0.0", "pg": "8.12.0", - "puppeteer": "^22.11.0", + "puppeteer": "^22.12.1", "textversionjs": "1.1.3", "voucher-code-generator": "1.3.0", "xkcd-api": "^1.0.1",