Skip to content

Commit

Permalink
devcontainer: Support for Puppeteer dependencies needed for slackbot …
Browse files Browse the repository at this point in the history
…functionality.
  • Loading branch information
hakatashi committed Nov 3, 2024
1 parent d30a268 commit 8452c30
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions .devcontainer/slackbot/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,20 @@ RUN apt-get update -y && \
# Install build dependencies for node-canvas
# https://github.com/Automattic/node-canvas/wiki/Installation%3A-Ubuntu-and-other-Debian-based-systems
apt-get install build-essential libcairo2-dev libpango1.0-dev libjpeg-dev libgif-dev librsvg2-dev -y && \
# Install git and bash
apt-get install git bash -y && \
# Install other dependencies
apt-get install git bash wget gnupg -y && \
# Install ngrok
curl -sSL https://ngrok-agent.s3.amazonaws.com/ngrok.asc | tee /etc/apt/trusted.gpg.d/ngrok.asc > /dev/null && \
echo "deb https://ngrok-agent.s3.amazonaws.com buster main" | tee /etc/apt/sources.list.d/ngrok.list && \
apt-get update && \
apt-get install ngrok -y && \
# Install Puppeteer dependencies
# https://source.chromium.org/chromium/chromium/src/+/main:chrome/installer/linux/debian/dist_package_versions.json;l=39-75;drc=df14ef63b2bc818472205e50ad32a3511db4edb2
wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | gpg --dearmor -o /usr/share/keyrings/googlechrome-linux-keyring.gpg && \
echo "deb [arch=amd64 signed-by=/usr/share/keyrings/googlechrome-linux-keyring.gpg] http://dl.google.com/linux/chrome/deb/ stable main" | tee /etc/apt/sources.list.d/google.list && \
apt-get update && \
apt-get install google-chrome-stable fonts-ipafont-gothic libasound2 libatk-bridge2.0-0 libatk1.0-0 libatspi2.0-0 libc6 libcairo2 libcups2 libdbus-1-3 libdrm2 libexpat1 libgbm1 libglib2.0-0 libnspr4 libnss3 libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libudev1 libuuid1 libx11-6 libx11-xcb1 libxcb-dri3-0 libxcb1 libxcomposite1 libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxkbcommon0 libxrandr2 libxrender1 libxshmfence1 libxss1 libxtst6 -y && \
# Install slackbot npm dependencies
mkdir -p ~/.cache/slackbot/node_modules && \
mkdir -p ~/.cache/slackbot-functions/node_modules && \
git clone https://github.com/tsg-ut/slackbot.git --branch master --single-branch --recursive --depth 1 /code && \
cd /code && \
npm install && \
Expand Down

0 comments on commit 8452c30

Please sign in to comment.