Skip to content

Commit

Permalink
use chrome v120
Browse files Browse the repository at this point in the history
  • Loading branch information
louisholley committed Jan 23, 2025
1 parent 9a6d80f commit 38ddaf6
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 78 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/build_image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,14 +35,14 @@ jobs:
.
docker push --all-tags $ECR_REGISTRY/$ECR_REPOSITORY
- name: Build, tag, and push Chrome v132 image to Amazon ECR
- name: Build, tag, and push Chrome v120 image to Amazon ECR
env:
ECR_REGISTRY: ${{ steps.login-ecr.outputs.registry }}
ECR_REPOSITORY: fxhash/chromium-extract
IMAGE_TAG: ${{ github.sha }}
run: |
docker build -f Dockerfile.v132 \
-t $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG-v132 \
-t $ECR_REGISTRY/$ECR_REPOSITORY:${GITHUB_REF##*/}-v132 \
docker build -f Dockerfile.v120 \
-t $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG-v120 \
-t $ECR_REGISTRY/$ECR_REPOSITORY:${GITHUB_REF##*/}-v120 \
.
docker push --all-tags $ECR_REGISTRY/$ECR_REPOSITORY
47 changes: 47 additions & 0 deletions Dockerfile.v120
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
FROM nvidia/opengl:1.2-glvnd-runtime-ubuntu20.04

# Set noninteractive installation
ENV DEBIAN_FRONTEND=noninteractive

# install curl for nodejs package
RUN apt-get update
RUN apt-get install -y curl wget gnupg

# Install specific version of Chrome
RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - \
&& echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list \
&& apt-get update \
&& apt-get install -y google-chrome-stable=120.0.6099.* \
&& apt-mark hold google-chrome-stable

# set node source
RUN curl -sL https://deb.nodesource.com/setup_16.x -o nodesource_setup.sh
RUN bash nodesource_setup.sh

# install dependencies
RUN DEBIAN_FRONTEND=noninteractive \
apt-get install -y \
xorg \
xserver-xorg \
xvfb \
libx11-dev \
libxext-dev \
nodejs

RUN npm install --global yarn

# tells puppeteer to use the chrome binaries
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true \
PUPPETEER_EXECUTABLE_PATH=/usr/bin/google-chrome

# instructs the container to have access to all the GPUs
ENV NVIDIA_VISIBLE_DEVICES all
ENV NVIDIA_DRIVER_CAPABILITIES all

# setup modules & project
WORKDIR /app
RUN rm -rf *
COPY package.json ./
COPY yarn.lock ./
RUN yarn install
COPY . .
74 changes: 0 additions & 74 deletions Dockerfile.v132

This file was deleted.

0 comments on commit 38ddaf6

Please sign in to comment.