Compare commits

...

13 commits
0.1.0 ... main

Author SHA1 Message Date
6569bc3e50 Merge pull request 'Bump forgejo-release to v2' (#1) from actions-update into main
Reviewed-on: https://forgejo.neshweb.net///CI-Docker-Images/unlighthouse/pulls/1
2024-08-06 12:27:06 +00:00
9357e8f1c0 Bump forgejo-release to v2 2024-08-06 12:26:59 +00:00
8850943428
Added description label
All checks were successful
/ build (push) Successful in 3m6s
/ release (push) Successful in 6s
2024-06-20 19:34:43 +02:00
6fc76e29d7
Reverted to bookwork
All checks were successful
/ release (push) Successful in 6s
/ build (push) Successful in 2m39s
2024-06-20 19:27:38 +02:00
7efab10371
Bumped chromium dependency
All checks were successful
/ release (push) Successful in 7s
/ build (push) Successful in 2m21s
2024-06-20 18:48:40 +02:00
429b05cca5
Bumped version of image
Some checks failed
/ release (push) Has been skipped
/ build (push) Failing after 44s
2024-06-20 18:46:59 +02:00
056ffe9b65
Bumped unlighthouse-ci and chromium versions, lighthouse 12 support
Some checks failed
/ release (push) Has been skipped
/ build (push) Failing after 1m11s
2024-06-20 18:38:41 +02:00
9e20764526
Updated README
All checks were successful
/ release (push) Successful in 37s
/ build (push) Successful in 3m39s
2023-12-29 13:12:36 +01:00
a856b33962
Updated workflow 2023-12-29 13:07:43 +01:00
3128c5cd9a
Updated Chrome Version
All checks were successful
/ build (push) Successful in 4m14s
/ release (push) Successful in 20s
2023-12-28 16:19:07 +01:00
eebcb039e0
Fixed CI for migration to group
Some checks failed
/ release (push) Has been skipped
/ build (push) Failing after 2m6s
2023-12-28 16:14:30 +01:00
732cad813b
fixed label
All checks were successful
/ build (push) Successful in 3m57s
/ release (push) Successful in 9s
2023-12-21 15:43:11 +01:00
41b6f5b7bc
added maintainer label
Some checks failed
/ build (push) Failing after 13s
/ release (push) Has been skipped
2023-12-21 15:36:49 +01:00
4 changed files with 38 additions and 7 deletions

View file

@ -19,7 +19,7 @@ jobs:
uses: docker/build-push-action@v5 uses: docker/build-push-action@v5
with: with:
push: true push: true
tags: forgejo.neshweb.net/firq/unlighthouse-docker:${{ github.ref_name }}, forgejo.neshweb.net/firq/unlighthouse-docker:latest tags: forgejo.neshweb.net/ci-docker-images/unlighthouse:${{ github.ref_name }}, forgejo.neshweb.net/ci-docker-images/unlighthouse:latest
release: release:
needs: [build] needs: [build]
@ -27,7 +27,7 @@ jobs:
runs-on: docker runs-on: docker
steps: steps:
- name: Release New Version - name: Release New Version
uses: actions/forgejo-release@v1 uses: actions/forgejo-release@v2
with: with:
direction: upload direction: upload
url: https://forgejo.neshweb.net url: https://forgejo.neshweb.net

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
.vscode/*

View file

@ -1,12 +1,15 @@
FROM node:20.10.0-bookworm FROM node:20.14.0-bookworm
LABEL authorname="firq"
LABEL description="unlighthouse container for ci-based lighthouse testing"
WORKDIR /unlighthouse WORKDIR /unlighthouse
# renovate: datasource=repology depName=debian_12/chromium versioning=loose # renovate: datasource=repology depName=debian_12/chromium versioning=loose
ENV CHROMIUM_VERSION="120.0.6099.109-1~deb12u1" ENV CHROMIUM_VERSION="126.0.6478.114-1~deb12u1"
ENV NODE_ENV='production' ENV NODE_ENV='production'
# Update path so executable can be run globally # Update path so executable can be run globally
ENV PATH="/unlighthouse/node_modules/.bin:${PATH}" ENV PATH="/unlighthouse/node_modules/.bin:${PATH}"
RUN apt-get update && apt-get -y install --no-install-recommends chromium=${CHROMIUM_VERSION} procps && rm -rf /var/lib/apt/lists/* RUN apt-get update && apt-get -y install --no-install-recommends chromium=${CHROMIUM_VERSION} procps && rm -rf /var/lib/apt/lists/*
RUN npm install @unlighthouse/cli puppeteer RUN npm install @unlighthouse/cli@0.13.1 puppeteer

View file

@ -1,3 +1,30 @@
# Docker image to run lighthouse, but without non-privileged user # unlighthouse Docker Image
Uses the full node:20-bookwork image instead of slim due to issues with GitLab lighthouse Docker Image based on `node:20.10.0-bookworm` with `chromium` and `unlighthouse` preinstalled.
It can be used for benchmarking a given site with lighthouse and to generate corresponding reports with ease.
## Usage
The unlighthouse cli can be used by running the command `unlighthouse` inside the container
```shell
unlighthouse-ci --site "https://preview.firq.dev/"
```
It is recommended to provide a `unlighthouse.config.ts` to reduce the amount of CLI arguments needed.
An example config can be found here:
```typescript
export default {
puppeteerOptions: {
args: ["--no-sandbox", "--disable-setuid-sandbox"],
},
ci: {
budget: 90,
buildStatic: true
},
outputPath: "unlighthouse-reports",
}
```