Switch package manager to pnpm

This commit is contained in:
Bastien Wirtz 2024-04-22 19:55:25 +02:00
parent 8326eba25f
commit 0740fb31b5
8 changed files with 4455 additions and 4015 deletions

View File

@ -23,16 +23,20 @@ jobs:
-
name: Checkout
uses: actions/checkout@v4
-
name: pnpm setup
uses: pnpm/action-setup@v3
with:
version: 8
-
name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'yarn'
cache: 'pnpm'
-
name: install dependencies
run: yarn install --frozen-lockfile --non-interactive
run: pnpm install --frozen-lockfile
-
name: Check code style & potentential issues
run: yarn lint
run: pnpm lint

View File

@ -13,11 +13,22 @@ jobs:
-
name: Checkout
uses: actions/checkout@v4
-
name: pnpm setup
uses: pnpm/action-setup@v3
with:
version: 8
-
name: Use Node.js 20
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
-
name: Build project
run: |
yarn install --frozen-lockfile --non-interactive
yarn build
pnpm install --frozen-lockfile
pnpm build
-
name: Create artifact
working-directory: "dist"

View File

@ -1,16 +1,21 @@
# build stage
FROM node:lts-alpine3.18 as build-stage
FROM node:lts-alpine3.19 as build-stage
ENV PNPM_HOME="/pnpm"
ENV PATH="$PNPM_HOME:$PATH"
RUN corepack enable
RUN corepack use pnpm@8
WORKDIR /app
COPY package.json ./
RUN yarn install --no-cache --frozen-lockfile --non-interactive
COPY package.json pnpm-lock.yaml ./
RUN pnpm install --frozen-lockfile
COPY . .
RUN yarn build
RUN pnpm build
# production stage
FROM alpine:3.18
FROM alpine:3.19
ENV GID 1000
ENV UID 1000

View File

@ -143,13 +143,8 @@ helm install homer djjudas21/homer -f values.yaml
### Build manually
```sh
# Using yarn (recommended)
yarn install
yarn build
# **OR** Using npm
npm install
npm run build
pnpm install
pnpm build
```
Then your dashboard is ready to use in the `/dist` directory.

View File

@ -3,13 +3,8 @@
If you want to contribute to Homer, please read the [contributing guidelines](https://github.com/bastienwirtz/homer/blob/main/CONTRIBUTING.md) first.
```sh
# Using yarn (recommended)
yarn install
yarn dev
# **OR** Using npm
npm install
npm run dev
pnpm install
pnpm dev
```
## Custom services

View File

@ -6,7 +6,7 @@ The principle is simple: save a sample output of the API used in the service in
## Start the mock server to expose dummy data
```sh
yarn mock
pnpm mock
```
## How to add a new services sample

4419
pnpm-lock.yaml Normal file

File diff suppressed because it is too large Load Diff

3989
yarn.lock

File diff suppressed because it is too large Load Diff