feat(ci): also cache cargo stuff
All checks were successful
🚀 Lint & Test & Deploy / release (push) Successful in 4m15s
All checks were successful
🚀 Lint & Test & Deploy / release (push) Successful in 4m15s
This commit is contained in:
@@ -9,6 +9,8 @@ on:
|
|||||||
|
|
||||||
env:
|
env:
|
||||||
PNPM_CACHE_FOLDER: ~/.pnpm-store
|
PNPM_CACHE_FOLDER: ~/.pnpm-store
|
||||||
|
CARGO_HOME: ~/.cargo
|
||||||
|
CARGO_TARGET_DIR: target
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
release:
|
release:
|
||||||
@@ -30,6 +32,17 @@ jobs:
|
|||||||
restore-keys: |
|
restore-keys: |
|
||||||
${{ runner.os }}-pnpm-
|
${{ runner.os }}-pnpm-
|
||||||
|
|
||||||
|
- name: 🦀 Cache Cargo
|
||||||
|
uses: actions/cache@v4
|
||||||
|
with:
|
||||||
|
path: |
|
||||||
|
~/.cargo/registry
|
||||||
|
~/.cargo/git
|
||||||
|
target
|
||||||
|
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
|
||||||
|
restore-keys: |
|
||||||
|
${{ runner.os }}-cargo-
|
||||||
|
|
||||||
- name: 📦 Install Dependencies
|
- name: 📦 Install Dependencies
|
||||||
run: pnpm install --frozen-lockfile --store-dir ${{ env.PNPM_CACHE_FOLDER }}
|
run: pnpm install --frozen-lockfile --store-dir ${{ env.PNPM_CACHE_FOLDER }}
|
||||||
|
|
||||||
|
|||||||
25
Dockerfile
25
Dockerfile
@@ -1,23 +1,20 @@
|
|||||||
# FROM jacoblincool/playwright:chromium-light
|
FROM node:25-bookworm-slim
|
||||||
FROM jacoblincool/playwright:firefox
|
|
||||||
|
|
||||||
# RUN apk add --no-cache curl git jq g++ make
|
RUN apt update && apt install -y \
|
||||||
RUN apt update && apt install -y curl git jq g++ make \
|
curl \
|
||||||
libgl1-mesa-dri \
|
git \
|
||||||
|
jq \
|
||||||
|
g++ \
|
||||||
|
make \
|
||||||
|
rclone \
|
||||||
libglapi-mesa \
|
libglapi-mesa \
|
||||||
libosmesa6 \
|
libosmesa6 \
|
||||||
mesa-utils \
|
xvfb
|
||||||
xvfb \
|
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
|
||||||
|
|
||||||
# Set Rust paths
|
|
||||||
ENV RUSTUP_HOME=/usr/local/rustup \
|
ENV RUSTUP_HOME=/usr/local/rustup \
|
||||||
CARGO_HOME=/usr/local/cargo \
|
CARGO_HOME=/usr/local/cargo \
|
||||||
PATH=/usr/local/cargo/bin:$PATH
|
PATH=/usr/local/cargo/bin:$PATH
|
||||||
|
|
||||||
ENV PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD=1
|
|
||||||
|
|
||||||
# Install Rust, wasm target, and pnpm
|
|
||||||
RUN curl --silent --show-error --location --fail --retry 3 \
|
RUN curl --silent --show-error --location --fail --retry 3 \
|
||||||
--proto '=https' --tlsv1.2 \
|
--proto '=https' --tlsv1.2 \
|
||||||
--output /tmp/rustup-init.sh https://sh.rustup.rs \
|
--output /tmp/rustup-init.sh https://sh.rustup.rs \
|
||||||
@@ -26,4 +23,6 @@ RUN curl --silent --show-error --location --fail --retry 3 \
|
|||||||
&& rustup target add wasm32-unknown-unknown \
|
&& rustup target add wasm32-unknown-unknown \
|
||||||
&& rm -rf /usr/local/rustup/toolchains/*/share/doc \
|
&& rm -rf /usr/local/rustup/toolchains/*/share/doc \
|
||||||
&& npm i -g pnpm \
|
&& npm i -g pnpm \
|
||||||
&& pnpx playwright install firefox
|
&& pnpx playwright install-deps \
|
||||||
|
&& pnpx playwright install --with-deps firefox \
|
||||||
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|||||||
Reference in New Issue
Block a user