Compare commits
11
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f6d59a06b1 | ||
|
|
62879c01dd | ||
|
|
900f9ca1aa | ||
|
|
d09fa8a8a6 | ||
|
|
3f58a298bf | ||
|
|
bcd3d2d700 | ||
|
|
bdd96e398a | ||
|
|
78906c7218 | ||
|
|
7997648c51 | ||
|
|
9cf59c8453 | ||
|
|
69b7d5f68b |
No files matched your search
+1
-5
@@ -9,8 +9,4 @@ README.md
|
|||||||
.git
|
.git
|
||||||
dev
|
dev
|
||||||
.build
|
.build
|
||||||
e2e
|
e2e
|
||||||
apps/nextjs/.next
|
|
||||||
.env
|
|
||||||
.env.*
|
|
||||||
!.env.example
|
|
||||||
@@ -41,14 +41,6 @@ DB_URL='FULL_PATH_TO_YOUR_SQLITE_DB_FILE'
|
|||||||
|
|
||||||
TURBO_TELEMETRY_DISABLED=1
|
TURBO_TELEMETRY_DISABLED=1
|
||||||
|
|
||||||
# Turborepo remote cache (optional, for faster CI/local builds)
|
|
||||||
# Uncomment and fill in to enable remote caching locally.
|
|
||||||
# CI uses GitHub secrets for these values automatically.
|
|
||||||
# TURBO_API=https://your-cache-worker.workers.dev
|
|
||||||
# TURBO_TEAM=team_your_team
|
|
||||||
# TURBO_TOKEN=your-turbo-token
|
|
||||||
# TURBO_REMOTE_CACHE_SIGNATURE_KEY=your-signature-key
|
|
||||||
|
|
||||||
# Comma-separated paths to Docker-compatible Unix sockets.
|
# Comma-separated paths to Docker-compatible Unix sockets.
|
||||||
# Useful for connecting to multiple runtimes (Docker + Podman) simultaneously.
|
# Useful for connecting to multiple runtimes (Docker + Podman) simultaneously.
|
||||||
# When unset and no TCP hosts configured, defaults to /var/run/docker.sock.
|
# When unset and no TCP hosts configured, defaults to /var/run/docker.sock.
|
||||||
|
|||||||
@@ -15,13 +15,6 @@ concurrency:
|
|||||||
|
|
||||||
env:
|
env:
|
||||||
FORCE_COLOR: 3
|
FORCE_COLOR: 3
|
||||||
SKIP_ENV_VALIDATION: true
|
|
||||||
TURBO_API: ${{ secrets.TURBO_API }}
|
|
||||||
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
|
|
||||||
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
|
|
||||||
TURBO_REMOTE_CACHE_SIGNATURE_KEY: ${{ secrets.TURBO_REMOTE_CACHE_SIGNATURE_KEY }}
|
|
||||||
TURBO_SCM_BASE: ${{ github.event.pull_request.base.sha || github.event.before || 'HEAD~1' }}
|
|
||||||
TURBO_SCM_HEAD: ${{ github.sha }}
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
lint:
|
lint:
|
||||||
@@ -29,8 +22,6 @@ jobs:
|
|||||||
timeout-minutes: 10
|
timeout-minutes: 10
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v6
|
- uses: actions/checkout@v6
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
|
|
||||||
- name: Setup
|
- name: Setup
|
||||||
uses: ./tooling/github/setup
|
uses: ./tooling/github/setup
|
||||||
@@ -40,35 +31,31 @@ jobs:
|
|||||||
run: cp .env.example .env
|
run: cp .env.example .env
|
||||||
|
|
||||||
- name: Lint
|
- name: Lint
|
||||||
run: pnpm turbo lint --affected && pnpm lint:ws
|
run: pnpm lint && pnpm lint:ws
|
||||||
|
|
||||||
format:
|
format:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
timeout-minutes: 10
|
timeout-minutes: 10
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v6
|
- uses: actions/checkout@v6
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
|
|
||||||
- name: Setup
|
- name: Setup
|
||||||
uses: ./tooling/github/setup
|
uses: ./tooling/github/setup
|
||||||
|
|
||||||
- name: Format
|
- name: Format
|
||||||
run: pnpm turbo format --affected --continue -- --cache --cache-location node_modules/.cache/.prettiercache
|
run: pnpm format
|
||||||
|
|
||||||
typecheck:
|
typecheck:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
timeout-minutes: 10
|
timeout-minutes: 10
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v6
|
- uses: actions/checkout@v6
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
|
|
||||||
- name: Setup
|
- name: Setup
|
||||||
uses: ./tooling/github/setup
|
uses: ./tooling/github/setup
|
||||||
|
|
||||||
- name: Typecheck
|
- name: Typecheck
|
||||||
run: pnpm turbo typecheck --affected
|
run: pnpm typecheck
|
||||||
|
|
||||||
test:
|
test:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
@@ -91,12 +78,11 @@ jobs:
|
|||||||
e2e:
|
e2e:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
timeout-minutes: 15
|
timeout-minutes: 15
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v6
|
- uses: actions/checkout@v6
|
||||||
- name: Setup
|
- name: Setup
|
||||||
uses: ./tooling/github/setup
|
uses: ./tooling/github/setup
|
||||||
- name: Set up Docker Buildx
|
|
||||||
uses: docker/setup-buildx-action@v4
|
|
||||||
- name: Build docker image
|
- name: Build docker image
|
||||||
id: build-docker-image
|
id: build-docker-image
|
||||||
uses: docker/build-push-action@v7
|
uses: docker/build-push-action@v7
|
||||||
@@ -104,11 +90,8 @@ jobs:
|
|||||||
platforms: linux/amd64
|
platforms: linux/amd64
|
||||||
context: .
|
context: .
|
||||||
push: false
|
push: false
|
||||||
load: true
|
|
||||||
tags: homarr-e2e
|
tags: homarr-e2e
|
||||||
network: host
|
network: host
|
||||||
cache-from: type=gha
|
|
||||||
cache-to: type=gha,mode=max
|
|
||||||
env:
|
env:
|
||||||
SKIP_ENV_VALIDATION: true
|
SKIP_ENV_VALIDATION: true
|
||||||
- name: Install playwright browsers
|
- name: Install playwright browsers
|
||||||
@@ -122,12 +105,10 @@ jobs:
|
|||||||
timeout-minutes: 10
|
timeout-minutes: 10
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v6
|
- uses: actions/checkout@v6
|
||||||
with:
|
|
||||||
fetch-depth: 0
|
|
||||||
- name: Setup
|
- name: Setup
|
||||||
uses: ./tooling/github/setup
|
uses: ./tooling/github/setup
|
||||||
- name: Copy env
|
- name: Copy env
|
||||||
shell: bash
|
shell: bash
|
||||||
run: cp .env.example .env
|
run: cp .env.example .env
|
||||||
- name: Build
|
- name: Build
|
||||||
run: pnpm turbo build --affected
|
run: pnpm build
|
||||||
@@ -1,27 +1,70 @@
|
|||||||
"use client";
|
"use client";
|
||||||
|
|
||||||
import { Box, Stack } from "@mantine/core";
|
import { useCallback, useRef } from "react";
|
||||||
|
import { Box, LoadingOverlay, Stack } from "@mantine/core";
|
||||||
|
|
||||||
|
import type { RouterOutputs } from "@homarr/api";
|
||||||
|
import { clientApi } from "@homarr/api/client";
|
||||||
import { useCurrentLayout, useRequiredBoard } from "@homarr/boards/context";
|
import { useCurrentLayout, useRequiredBoard } from "@homarr/boards/context";
|
||||||
|
|
||||||
import { BoardCategorySection } from "~/components/board/sections/category-section";
|
import { BoardCategorySection } from "~/components/board/sections/category-section";
|
||||||
import { BoardEmptySection } from "~/components/board/sections/empty-section";
|
import { BoardEmptySection } from "~/components/board/sections/empty-section";
|
||||||
import { BoardBackgroundVideo } from "~/components/layout/background";
|
import { BoardBackgroundVideo } from "~/components/layout/background";
|
||||||
|
import { fullHeightWithoutHeaderAndFooter } from "~/constants";
|
||||||
|
import { useIsBoardReady } from "./_ready-context";
|
||||||
|
|
||||||
|
let boardName: string | null = null;
|
||||||
|
|
||||||
|
export const updateBoardName = (name: string | null) => {
|
||||||
|
boardName = name;
|
||||||
|
};
|
||||||
|
|
||||||
|
type UpdateCallback = (prev: RouterOutputs["board"]["getHomeBoard"]) => RouterOutputs["board"]["getHomeBoard"];
|
||||||
|
|
||||||
|
export const useUpdateBoard = () => {
|
||||||
|
const utils = clientApi.useUtils();
|
||||||
|
|
||||||
|
const updateBoard = useCallback(
|
||||||
|
(updaterWithoutUndefined: UpdateCallback) => {
|
||||||
|
if (!boardName) {
|
||||||
|
throw new Error("Board name is not set");
|
||||||
|
}
|
||||||
|
utils.board.getBoardByName.setData({ name: boardName }, (previous) =>
|
||||||
|
previous ? updaterWithoutUndefined(previous) : previous,
|
||||||
|
);
|
||||||
|
},
|
||||||
|
[utils],
|
||||||
|
);
|
||||||
|
|
||||||
|
return {
|
||||||
|
updateBoard,
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
export const ClientBoard = () => {
|
export const ClientBoard = () => {
|
||||||
const board = useRequiredBoard();
|
const board = useRequiredBoard();
|
||||||
const currentLayoutId = useCurrentLayout();
|
const currentLayoutId = useCurrentLayout();
|
||||||
|
const isReady = useIsBoardReady();
|
||||||
|
|
||||||
const fullWidthSortedSections = board.sections
|
const fullWidthSortedSections = board.sections
|
||||||
.filter((section) => section.kind === "empty" || section.kind === "category")
|
.filter((section) => section.kind === "empty" || section.kind === "category")
|
||||||
.sort((sectionA, sectionB) => sectionA.yOffset - sectionB.yOffset);
|
.sort((sectionA, sectionB) => sectionA.yOffset - sectionB.yOffset);
|
||||||
|
|
||||||
|
const ref = useRef<HTMLDivElement>(null);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Box h="100%" pos="relative">
|
<Box h="100%" pos="relative">
|
||||||
<BoardBackgroundVideo />
|
<BoardBackgroundVideo />
|
||||||
<Stack h="100%">
|
<LoadingOverlay
|
||||||
|
visible={!isReady}
|
||||||
|
transitionProps={{ duration: 500 }}
|
||||||
|
loaderProps={{ size: "lg" }}
|
||||||
|
h={fullHeightWithoutHeaderAndFooter}
|
||||||
|
/>
|
||||||
|
<Stack ref={ref} h="100%" style={{ visibility: isReady ? "visible" : "hidden" }}>
|
||||||
{fullWidthSortedSections.map((section) =>
|
{fullWidthSortedSections.map((section) =>
|
||||||
section.kind === "empty" ? (
|
section.kind === "empty" ? (
|
||||||
|
// Unique keys per layout to always reinitialize the gridstack
|
||||||
<BoardEmptySection key={`${currentLayoutId}-${section.id}`} section={section} />
|
<BoardEmptySection key={`${currentLayoutId}-${section.id}`} section={section} />
|
||||||
) : (
|
) : (
|
||||||
<BoardCategorySection key={`${currentLayoutId}-${section.id}`} section={section} />
|
<BoardCategorySection key={`${currentLayoutId}-${section.id}`} section={section} />
|
||||||
|
|||||||
@@ -1,19 +1,42 @@
|
|||||||
"use client";
|
"use client";
|
||||||
|
|
||||||
import type { PropsWithChildren } from "react";
|
import type { PropsWithChildren } from "react";
|
||||||
import { createContext, useCallback, useContext } from "react";
|
import { createContext, useCallback, useContext, useEffect, useState } from "react";
|
||||||
|
import { usePathname } from "next/navigation";
|
||||||
|
|
||||||
|
import { clientApi } from "@homarr/api/client";
|
||||||
|
import { useRequiredBoard } from "@homarr/boards/context";
|
||||||
|
|
||||||
const BoardReadyContext = createContext<{
|
const BoardReadyContext = createContext<{
|
||||||
|
isReady: boolean;
|
||||||
markAsReady: (id: string) => void;
|
markAsReady: (id: string) => void;
|
||||||
} | null>(null);
|
} | null>(null);
|
||||||
|
|
||||||
export const BoardReadyProvider = ({ children }: PropsWithChildren) => {
|
export const BoardReadyProvider = ({ children }: PropsWithChildren) => {
|
||||||
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
const pathname = usePathname();
|
||||||
const markAsReady = useCallback((_id: string) => {}, []);
|
const utils = clientApi.useUtils();
|
||||||
|
const board = useRequiredBoard();
|
||||||
|
const [readySections, setReadySections] = useState<string[]>([]);
|
||||||
|
|
||||||
|
// Reset sections required for ready state
|
||||||
|
useEffect(() => {
|
||||||
|
return () => {
|
||||||
|
setReadySections([]);
|
||||||
|
};
|
||||||
|
}, [pathname, utils]);
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
setReadySections((previous) => previous.filter((id) => board.sections.some((section) => section.id === id)));
|
||||||
|
}, [board.sections.length, setReadySections]);
|
||||||
|
|
||||||
|
const markAsReady = useCallback((id: string) => {
|
||||||
|
setReadySections((previous) => (previous.includes(id) ? previous : [...previous, id]));
|
||||||
|
}, []);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<BoardReadyContext.Provider
|
<BoardReadyContext.Provider
|
||||||
value={{
|
value={{
|
||||||
|
isReady: board.sections.length === readySections.length,
|
||||||
markAsReady,
|
markAsReady,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@@ -31,3 +54,13 @@ export const useMarkSectionAsReady = () => {
|
|||||||
|
|
||||||
return context.markAsReady;
|
return context.markAsReady;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export const useIsBoardReady = () => {
|
||||||
|
const context = useContext(BoardReadyContext);
|
||||||
|
|
||||||
|
if (!context) {
|
||||||
|
throw new Error("BoardReadyProvider is required");
|
||||||
|
}
|
||||||
|
|
||||||
|
return context.isReady;
|
||||||
|
};
|
||||||
@@ -9,5 +9,5 @@
|
|||||||
"tsBuildInfoFile": "node_modules/.cache/tsbuildinfo.json"
|
"tsBuildInfoFile": "node_modules/.cache/tsbuildinfo.json"
|
||||||
},
|
},
|
||||||
"include": ["."],
|
"include": ["."],
|
||||||
"exclude": ["node_modules", "*.cjs", "*.css"]
|
"exclude": ["node_modules"]
|
||||||
}
|
}
|
||||||
@@ -9,5 +9,5 @@
|
|||||||
"tsBuildInfoFile": "node_modules/.cache/tsbuildinfo.json"
|
"tsBuildInfoFile": "node_modules/.cache/tsbuildinfo.json"
|
||||||
},
|
},
|
||||||
"include": ["."],
|
"include": ["."],
|
||||||
"exclude": ["node_modules", "*.cjs", "*.css"]
|
"exclude": ["node_modules"]
|
||||||
}
|
}
|
||||||
@@ -2,7 +2,7 @@
|
|||||||
"name": "homarr-prebuilt-debian",
|
"name": "homarr-prebuilt-debian",
|
||||||
"private": true,
|
"private": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"better-sqlite3": "^12.10.0"
|
"better-sqlite3": "^12.9.0"
|
||||||
},
|
},
|
||||||
"packageManager": "pnpm@10.33.4",
|
"packageManager": "pnpm@10.33.4",
|
||||||
"engines": {
|
"engines": {
|
||||||
|
|||||||
+6
-6
@@ -9,17 +9,17 @@ importers:
|
|||||||
.:
|
.:
|
||||||
dependencies:
|
dependencies:
|
||||||
better-sqlite3:
|
better-sqlite3:
|
||||||
specifier: ^12.10.0
|
specifier: ^12.9.0
|
||||||
version: 12.10.0
|
version: 12.9.0
|
||||||
|
|
||||||
packages:
|
packages:
|
||||||
|
|
||||||
base64-js@1.5.1:
|
base64-js@1.5.1:
|
||||||
resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==}
|
resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==}
|
||||||
|
|
||||||
better-sqlite3@12.10.0:
|
better-sqlite3@12.9.0:
|
||||||
resolution: {integrity: sha512-CyzaZRQKyHkB2ZInfTTl2nvT33EbDpjkLEbE8/Zck3Ll6O0qqvuGdrJ45HgtH+HykRg88ITY3AdreBGN70aBSQ==}
|
resolution: {integrity: sha512-wqUv4Gm3toFpHDQmaKD4QhZm3g1DjUBI0yzS4UBl6lElUmXFYdTQmmEDpAFa5o8FiFiymURypEnfVHzILKaxqQ==}
|
||||||
engines: {node: 20.x || 22.x || 23.x || 24.x || 25.x || 26.x}
|
engines: {node: 20.x || 22.x || 23.x || 24.x || 25.x}
|
||||||
|
|
||||||
bindings@1.5.0:
|
bindings@1.5.0:
|
||||||
resolution: {integrity: sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==}
|
resolution: {integrity: sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==}
|
||||||
@@ -148,7 +148,7 @@ snapshots:
|
|||||||
|
|
||||||
base64-js@1.5.1: {}
|
base64-js@1.5.1: {}
|
||||||
|
|
||||||
better-sqlite3@12.10.0:
|
better-sqlite3@12.9.0:
|
||||||
dependencies:
|
dependencies:
|
||||||
bindings: 1.5.0
|
bindings: 1.5.0
|
||||||
prebuild-install: 7.1.3
|
prebuild-install: 7.1.3
|
||||||
|
|||||||
+3
-3
@@ -85,18 +85,18 @@
|
|||||||
"brace-expansion@>=1.0.0 <=1.1.11": ">=5.0.6",
|
"brace-expansion@>=1.0.0 <=1.1.11": ">=5.0.6",
|
||||||
"esbuild@<=0.24.2": ">=0.28.0",
|
"esbuild@<=0.24.2": ">=0.28.0",
|
||||||
"form-data@>=4.0.0 <4.0.4": ">=4.0.5",
|
"form-data@>=4.0.0 <4.0.4": ">=4.0.5",
|
||||||
"hono@<4.6.5": ">=4.12.19",
|
"hono@<4.6.5": ">=4.12.16",
|
||||||
"linkifyjs@<4.3.2": ">=4.3.3",
|
"linkifyjs@<4.3.2": ">=4.3.3",
|
||||||
"nanoid@>=4.0.0 <5.0.9": ">=5.1.11",
|
"nanoid@>=4.0.0 <5.0.9": ">=5.1.11",
|
||||||
"prismjs@<1.30.0": ">=1.30.0",
|
"prismjs@<1.30.0": ">=1.30.0",
|
||||||
"proxmox-api>undici": "7.24.6",
|
"proxmox-api>undici": "7.24.6",
|
||||||
"react-is": "^19.2.6",
|
"react-is": "^19.2.6",
|
||||||
"rollup@>=4.0.0 <4.22.4": ">=4.60.4",
|
"rollup@>=4.0.0 <4.22.4": ">=4.60.3",
|
||||||
"sha.js@<=2.4.11": ">=2.4.12",
|
"sha.js@<=2.4.11": ">=2.4.12",
|
||||||
"tar-fs@>=3.0.0 <3.0.9": ">=3.1.2",
|
"tar-fs@>=3.0.0 <3.0.9": ">=3.1.2",
|
||||||
"tar-fs@>=2.0.0 <2.1.3": ">=3.1.2",
|
"tar-fs@>=2.0.0 <2.1.3": ">=3.1.2",
|
||||||
"tmp@<=0.2.3": ">=0.2.5",
|
"tmp@<=0.2.3": ">=0.2.5",
|
||||||
"vite@>=5.0.0 <=5.4.18": ">=8.0.13"
|
"vite@>=5.0.0 <=5.4.18": ">=8.0.12"
|
||||||
},
|
},
|
||||||
"patchedDependencies": {
|
"patchedDependencies": {
|
||||||
"@types/node-unifi": "patches/@types__node-unifi.patch",
|
"@types/node-unifi": "patches/@types__node-unifi.patch",
|
||||||
|
|||||||
@@ -5,26 +5,3 @@ export const capitalize = <T extends string>(str: T) => {
|
|||||||
export const isNullOrWhitespace = (value: string | null): value is null => {
|
export const isNullOrWhitespace = (value: string | null): value is null => {
|
||||||
return value == null || value.trim() === "";
|
return value == null || value.trim() === "";
|
||||||
};
|
};
|
||||||
|
|
||||||
export const bestMatch = <TItem extends Record<string, unknown>>(
|
|
||||||
search: string,
|
|
||||||
options: TItem[],
|
|
||||||
by: (item: TItem) => string,
|
|
||||||
) => {
|
|
||||||
if (options.length === 0) return null;
|
|
||||||
|
|
||||||
const normalizedSearch = search.toLowerCase().trim();
|
|
||||||
|
|
||||||
return options.reduce<TItem | null>((best, current) => {
|
|
||||||
const currentMatchIndex = by(current).toLowerCase().indexOf(normalizedSearch);
|
|
||||||
|
|
||||||
if (currentMatchIndex === -1) return best;
|
|
||||||
if (best === null) return current;
|
|
||||||
|
|
||||||
const bestMatchIndex = by(best).toLowerCase().indexOf(normalizedSearch);
|
|
||||||
|
|
||||||
if (currentMatchIndex < bestMatchIndex) return current;
|
|
||||||
if (by(current).length < by(best).length && currentMatchIndex === bestMatchIndex) return current;
|
|
||||||
return best;
|
|
||||||
}, null);
|
|
||||||
};
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import { describe, expect, test } from "vitest";
|
import { describe, expect, it } from "vitest";
|
||||||
|
|
||||||
import { bestMatch, capitalize } from "../string";
|
import { capitalize } from "../string";
|
||||||
|
|
||||||
const capitalizeTestCases = [
|
const capitalizeTestCases = [
|
||||||
["hello", "Hello"],
|
["hello", "Hello"],
|
||||||
@@ -12,45 +12,8 @@ const capitalizeTestCases = [
|
|||||||
|
|
||||||
describe("capitalize should capitalize the first letter of a string", () => {
|
describe("capitalize should capitalize the first letter of a string", () => {
|
||||||
capitalizeTestCases.forEach(([input, expected]) => {
|
capitalizeTestCases.forEach(([input, expected]) => {
|
||||||
test(`should capitalize ${input} to ${expected}`, () => {
|
it(`should capitalize ${input} to ${expected}`, () => {
|
||||||
expect(capitalize(input)).toEqual(expected);
|
expect(capitalize(input)).toEqual(expected);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("bestMatch should find the best match in an array of options", () => {
|
|
||||||
test("should find exact match for 'nginx'", () => {
|
|
||||||
const options = [
|
|
||||||
{ name: "my-nginx" },
|
|
||||||
{ name: "nginx-proxy" },
|
|
||||||
{ name: "nginx" },
|
|
||||||
{ name: "redis" },
|
|
||||||
{ name: "postgres" },
|
|
||||||
];
|
|
||||||
|
|
||||||
const result = bestMatch("nginx", options, ({ name }) => name);
|
|
||||||
|
|
||||||
expect(result).toEqual({ name: "nginx" });
|
|
||||||
});
|
|
||||||
test("should find closest match for 'nginx' when exact match is not available", () => {
|
|
||||||
const options = [{ name: "redis" }, { name: "nginx-proxy" }, { name: "my-nginx" }, { name: "postgres" }];
|
|
||||||
|
|
||||||
const result = bestMatch("nginx", options, ({ name }) => name);
|
|
||||||
|
|
||||||
expect(result).toEqual({ name: "nginx-proxy" });
|
|
||||||
});
|
|
||||||
test("should return null if no match is found", () => {
|
|
||||||
const options = [{ name: "redis" }, { name: "postgres" }];
|
|
||||||
|
|
||||||
const result = bestMatch("nginx", options, ({ name }) => name);
|
|
||||||
|
|
||||||
expect(result).toBeNull();
|
|
||||||
});
|
|
||||||
test("should return null if options array is empty", () => {
|
|
||||||
const options: { name: string }[] = [];
|
|
||||||
|
|
||||||
const result = bestMatch("nginx", options, ({ name }) => name);
|
|
||||||
|
|
||||||
expect(result).toBeNull();
|
|
||||||
});
|
|
||||||
});
|
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
import { describe, expect, test } from "vitest";
|
import { describe, expect, test } from "vitest";
|
||||||
|
|
||||||
import { getPortFromUrl, isAbsoluteUrl } from "../url.js";
|
import { getPortFromUrl } from "../url";
|
||||||
|
|
||||||
describe("getPortFromUrl", () => {
|
describe("getPortFromUrl", () => {
|
||||||
test.each([
|
test.each([
|
||||||
@@ -38,21 +38,3 @@ describe("getPortFromUrl", () => {
|
|||||||
expect(act).toThrowError("Unsupported protocol: ftp:");
|
expect(act).toThrowError("Unsupported protocol: ftp:");
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
describe("isAbsoluteUrl", () => {
|
|
||||||
test.each([
|
|
||||||
["http://example.com", true],
|
|
||||||
["https://example.com", true],
|
|
||||||
["ftp://example.com", true],
|
|
||||||
["file:///path/to/file", true],
|
|
||||||
["mailto:johndoe@example.com", true],
|
|
||||||
["/relative/path", false],
|
|
||||||
["relative/path", false],
|
|
||||||
])("should return %s for URL: %s", (urlString, expected) => {
|
|
||||||
// Act
|
|
||||||
const result = isAbsoluteUrl(urlString);
|
|
||||||
|
|
||||||
// Assert
|
|
||||||
expect(result).toBe(expected);
|
|
||||||
});
|
|
||||||
});
|
|
||||||
@@ -38,9 +38,3 @@ export const getPortFromUrl = (url: URL): number => {
|
|||||||
|
|
||||||
throw new Error(`Unsupported protocol: ${url.protocol}`);
|
throw new Error(`Unsupported protocol: ${url.protocol}`);
|
||||||
};
|
};
|
||||||
|
|
||||||
const absoluteUrlRegex = /^[a-z]+:(\/\/)?/;
|
|
||||||
|
|
||||||
export const isAbsoluteUrl = (urlOrPath: string): boolean => {
|
|
||||||
return absoluteUrlRegex.test(urlOrPath.toLowerCase());
|
|
||||||
};
|
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
import { createId, objectKeys } from "@homarr/common";
|
import { createId, objectKeys } from "@homarr/common";
|
||||||
import {
|
import {
|
||||||
createDocumentationLink,
|
createDocumentationLink,
|
||||||
credentialsAdminGroup,
|
|
||||||
everyoneGroup,
|
everyoneGroup,
|
||||||
getIntegrationDefaultUrl,
|
getIntegrationDefaultUrl,
|
||||||
getIntegrationName,
|
getIntegrationName,
|
||||||
@@ -12,24 +11,12 @@ import { defaultServerSettings, defaultServerSettingsKeys } from "@homarr/server
|
|||||||
|
|
||||||
import type { Database } from "..";
|
import type { Database } from "..";
|
||||||
import { eq } from "..";
|
import { eq } from "..";
|
||||||
import { getMaxGroupPositionAsync } from "../queries";
|
|
||||||
import {
|
import {
|
||||||
getServerSettingByKeyAsync,
|
getServerSettingByKeyAsync,
|
||||||
insertServerSettingByKeyAsync,
|
insertServerSettingByKeyAsync,
|
||||||
updateServerSettingByKeyAsync,
|
updateServerSettingByKeyAsync,
|
||||||
} from "../queries/server-setting";
|
} from "../queries/server-setting";
|
||||||
import {
|
import { groups, integrations, onboarding, searchEngines } from "../schema";
|
||||||
boards,
|
|
||||||
groupMembers,
|
|
||||||
groupPermissions,
|
|
||||||
groups,
|
|
||||||
integrations,
|
|
||||||
layouts,
|
|
||||||
onboarding,
|
|
||||||
searchEngines,
|
|
||||||
sections,
|
|
||||||
users,
|
|
||||||
} from "../schema";
|
|
||||||
import type { Integration } from "../schema";
|
import type { Integration } from "../schema";
|
||||||
|
|
||||||
export const seedDataAsync = async (db: Database) => {
|
export const seedDataAsync = async (db: Database) => {
|
||||||
@@ -38,10 +25,6 @@ export const seedDataAsync = async (db: Database) => {
|
|||||||
await seedServerSettingsAsync(db);
|
await seedServerSettingsAsync(db);
|
||||||
await seedDefaultSearchEnginesAsync(db);
|
await seedDefaultSearchEnginesAsync(db);
|
||||||
await seedDefaultIntegrationsAsync(db);
|
await seedDefaultIntegrationsAsync(db);
|
||||||
|
|
||||||
if (process.env.DEMO_MODE === "true") {
|
|
||||||
await seedDemoUserAsync(db);
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const seedEveryoneGroupAsync = async (db: Database) => {
|
const seedEveryoneGroupAsync = async (db: Database) => {
|
||||||
@@ -208,72 +191,3 @@ const seedDefaultIntegrationsAsync = async (db: Database) => {
|
|||||||
|
|
||||||
console.log(`Created ${createdCount} default integrations through seeding process`);
|
console.log(`Created ${createdCount} default integrations through seeding process`);
|
||||||
};
|
};
|
||||||
|
|
||||||
const seedDemoUserAsync = async (db: Database) => {
|
|
||||||
const existingUser = await db.query.users.findFirst({
|
|
||||||
where: eq(users.name, "demo"),
|
|
||||||
});
|
|
||||||
|
|
||||||
if (existingUser) {
|
|
||||||
console.log("Skipping seeding of demo user as it already exists");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
const userId = createId();
|
|
||||||
|
|
||||||
await db.insert(users).values({
|
|
||||||
id: userId,
|
|
||||||
name: "demo",
|
|
||||||
email: "demo@example.com",
|
|
||||||
password: "$2b$10$c5AaQb0oj32/bui5Z55PyOb7pY.iEkXYqgdD8MjS9LjSjLMeOkZu2",
|
|
||||||
});
|
|
||||||
|
|
||||||
const maxPosition = await getMaxGroupPositionAsync(db);
|
|
||||||
const groupId = createId();
|
|
||||||
await db.insert(groups).values({
|
|
||||||
id: groupId,
|
|
||||||
name: credentialsAdminGroup,
|
|
||||||
ownerId: userId,
|
|
||||||
position: maxPosition + 1,
|
|
||||||
});
|
|
||||||
await db.insert(groupPermissions).values({
|
|
||||||
groupId,
|
|
||||||
permission: "admin",
|
|
||||||
});
|
|
||||||
await db.insert(groupMembers).values({
|
|
||||||
groupId,
|
|
||||||
userId,
|
|
||||||
});
|
|
||||||
|
|
||||||
await db.update(onboarding).set({
|
|
||||||
step: "finish",
|
|
||||||
previousStep: "settings",
|
|
||||||
});
|
|
||||||
|
|
||||||
const boardId = createId();
|
|
||||||
await db.insert(boards).values({
|
|
||||||
id: boardId,
|
|
||||||
name: "default",
|
|
||||||
isPublic: false,
|
|
||||||
creatorId: userId,
|
|
||||||
});
|
|
||||||
await db.insert(sections).values({
|
|
||||||
id: createId(),
|
|
||||||
kind: "empty",
|
|
||||||
xOffset: 0,
|
|
||||||
yOffset: 0,
|
|
||||||
boardId,
|
|
||||||
});
|
|
||||||
await db.insert(layouts).values({
|
|
||||||
id: createId(),
|
|
||||||
name: "Base",
|
|
||||||
columnCount: 12,
|
|
||||||
breakpoint: 0,
|
|
||||||
boardId,
|
|
||||||
});
|
|
||||||
await db.update(users).set({ homeBoardId: boardId }).where(eq(users.id, userId));
|
|
||||||
|
|
||||||
console.log(
|
|
||||||
"Your instance has enabled demo mode. Homarr therefore created example data for your demo. You can disable demo mode anytime by setting the env 'DEMO_MODE' to 'false' or unset it.",
|
|
||||||
);
|
|
||||||
};
|
|
||||||
@@ -1,4 +1,3 @@
|
|||||||
import { isAbsoluteUrl } from "@homarr/common";
|
|
||||||
import { ResponseError } from "@homarr/common/server";
|
import { ResponseError } from "@homarr/common/server";
|
||||||
import { fetchWithTrustedCertificatesAsync } from "@homarr/core/infrastructure/http";
|
import { fetchWithTrustedCertificatesAsync } from "@homarr/core/infrastructure/http";
|
||||||
import { ImageProxy } from "@homarr/image-proxy";
|
import { ImageProxy } from "@homarr/image-proxy";
|
||||||
@@ -86,10 +85,10 @@ export class TracearrIntegration extends Integration {
|
|||||||
data: await Promise.all(
|
data: await Promise.all(
|
||||||
json.data.map(async (stream) => {
|
json.data.map(async (stream) => {
|
||||||
if (stream.userAvatarUrl) {
|
if (stream.userAvatarUrl) {
|
||||||
stream.userAvatarUrl = await this.proxyImageAsync(imageProxy, stream.userAvatarUrl);
|
stream.userAvatarUrl = await this.proxyImageAsync(imageProxy, stream.userAvatarUrl, stream.id, "avatar");
|
||||||
}
|
}
|
||||||
if (stream.posterUrl) {
|
if (stream.posterUrl) {
|
||||||
stream.posterUrl = await this.proxyImageAsync(imageProxy, stream.posterUrl);
|
stream.posterUrl = await this.proxyImageAsync(imageProxy, stream.posterUrl, stream.id, "poster");
|
||||||
}
|
}
|
||||||
return stream;
|
return stream;
|
||||||
}),
|
}),
|
||||||
@@ -121,7 +120,12 @@ export class TracearrIntegration extends Integration {
|
|||||||
...json,
|
...json,
|
||||||
data: await Promise.all(
|
data: await Promise.all(
|
||||||
json.data.map(async (violation) => {
|
json.data.map(async (violation) => {
|
||||||
violation.user.avatarUrl = await this.proxyImageAsync(imageProxy, violation.user.avatarUrl);
|
violation.user.avatarUrl = await this.proxyImageAsync(
|
||||||
|
imageProxy,
|
||||||
|
violation.user.avatarUrl,
|
||||||
|
violation.user.id,
|
||||||
|
"avatar",
|
||||||
|
);
|
||||||
return violation;
|
return violation;
|
||||||
}),
|
}),
|
||||||
),
|
),
|
||||||
@@ -152,7 +156,12 @@ export class TracearrIntegration extends Integration {
|
|||||||
...json,
|
...json,
|
||||||
data: await Promise.all(
|
data: await Promise.all(
|
||||||
json.data.map(async (session) => {
|
json.data.map(async (session) => {
|
||||||
session.user.avatarUrl = await this.proxyImageAsync(imageProxy, session.user.avatarUrl);
|
session.user.avatarUrl = await this.proxyImageAsync(
|
||||||
|
imageProxy,
|
||||||
|
session.user.avatarUrl,
|
||||||
|
session.user.id,
|
||||||
|
"avatar",
|
||||||
|
);
|
||||||
return session;
|
return session;
|
||||||
}),
|
}),
|
||||||
),
|
),
|
||||||
@@ -185,12 +194,23 @@ export class TracearrIntegration extends Integration {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
private async proxyImageAsync(imageProxy: ImageProxy, urlOrPath: string | null | undefined): Promise<string | null> {
|
private async proxyImageAsync(
|
||||||
if (!urlOrPath) return null;
|
imageProxy: ImageProxy,
|
||||||
|
url: string | null | undefined,
|
||||||
|
uniqueId: string,
|
||||||
|
discriminator: string,
|
||||||
|
): Promise<string | null> {
|
||||||
|
if (!url) return null;
|
||||||
try {
|
try {
|
||||||
// ImageProxy doesn't support fallback urls so we need to remove them
|
// ImageProxy doesn't support fallback urls so we need to remove them
|
||||||
const cleanUrl = urlOrPath.replace(/&fallback=[^&]+/, "").replace(/\?fallback=[^&]+&?/, "?");
|
const cleanUrl = url.replace(/&fallback=[^&]+/, "").replace(/\?fallback=[^&]+&?/, "?");
|
||||||
const fullUrl = isAbsoluteUrl(urlOrPath) ? cleanUrl : this.url(cleanUrl as `/${string}`).toString();
|
// Build the full URL, then inject _uid as the FIRST query param.
|
||||||
|
// This is critical because ImageProxy uses bcrypt which truncates at 72 bytes.
|
||||||
|
// Without this, all long avatar/poster URLs from the same session hash identically
|
||||||
|
// since they share the same first 72+ bytes.
|
||||||
|
const baseUrl = this.url(cleanUrl as `/${string}`).toString();
|
||||||
|
const prefix = `_uid=${discriminator}_${uniqueId}&`;
|
||||||
|
const fullUrl = baseUrl.includes("?") ? baseUrl.replace("?", `?${prefix}`) : `${baseUrl}?${prefix}`;
|
||||||
|
|
||||||
return await imageProxy.createImageAsync(fullUrl, this.getAuthHeaders());
|
return await imageProxy.createImageAsync(fullUrl, this.getAuthHeaders());
|
||||||
} catch {
|
} catch {
|
||||||
|
|||||||
@@ -2,7 +2,6 @@ import dayjs from "dayjs";
|
|||||||
import type { ContainerInfo, ContainerStats } from "dockerode";
|
import type { ContainerInfo, ContainerStats } from "dockerode";
|
||||||
import type Dockerode from "dockerode";
|
import type Dockerode from "dockerode";
|
||||||
|
|
||||||
import { bestMatch } from "@homarr/common";
|
|
||||||
import { createLogger } from "@homarr/core/infrastructure/logs";
|
import { createLogger } from "@homarr/core/infrastructure/logs";
|
||||||
import { ErrorWithMetadata } from "@homarr/core/infrastructure/logs/error";
|
import { ErrorWithMetadata } from "@homarr/core/infrastructure/logs/error";
|
||||||
import { db, like, or } from "@homarr/db";
|
import { db, like, or } from "@homarr/db";
|
||||||
@@ -83,7 +82,12 @@ async function getContainersWithStatsAsync() {
|
|||||||
name: container.Names[0]?.split("/")[1] ?? "Unknown",
|
name: container.Names[0]?.split("/")[1] ?? "Unknown",
|
||||||
host: container.instance,
|
host: container.instance,
|
||||||
state: container.State as ContainerState,
|
state: container.State as ContainerState,
|
||||||
iconUrl: bestMatch(extractImage(container), dbIcons, (icon) => icon.name)?.url ?? null,
|
iconUrl:
|
||||||
|
dbIcons.find((icon) => {
|
||||||
|
const extractedImage = extractImage(container);
|
||||||
|
if (!extractedImage) return false;
|
||||||
|
return icon.name.toLowerCase().includes(extractedImage.toLowerCase());
|
||||||
|
})?.url ?? null,
|
||||||
cpuUsage,
|
cpuUsage,
|
||||||
memoryUsage,
|
memoryUsage,
|
||||||
image: container.Image,
|
image: container.Image,
|
||||||
|
|||||||
Generated
+347
-313
File diff suppressed because it is too large.
Load diff
+24
-26
@@ -36,7 +36,7 @@ catalog:
|
|||||||
"@next/eslint-plugin-next": 16.2.6
|
"@next/eslint-plugin-next": 16.2.6
|
||||||
"@octokit/auth-app": ^8.2.0
|
"@octokit/auth-app": ^8.2.0
|
||||||
"@paralleldrive/cuid2": ^3.3.0
|
"@paralleldrive/cuid2": ^3.3.0
|
||||||
"@playwright/test": ^1.60.0
|
"@playwright/test": ^1.59.1
|
||||||
"@semantic-release/changelog": ^6.0.3
|
"@semantic-release/changelog": ^6.0.3
|
||||||
"@semantic-release/commit-analyzer": ^13.0.1
|
"@semantic-release/commit-analyzer": ^13.0.1
|
||||||
"@semantic-release/git": ^10.0.1
|
"@semantic-release/git": ^10.0.1
|
||||||
@@ -51,28 +51,28 @@ catalog:
|
|||||||
"@testcontainers/mysql": ^11.14.0
|
"@testcontainers/mysql": ^11.14.0
|
||||||
"@testcontainers/postgresql": ^11.14.0
|
"@testcontainers/postgresql": ^11.14.0
|
||||||
"@testcontainers/redis": ^11.14.0
|
"@testcontainers/redis": ^11.14.0
|
||||||
"@tiptap/extension-color": 3.23.4
|
"@tiptap/extension-color": 3.23.2
|
||||||
"@tiptap/extension-highlight": 3.23.4
|
"@tiptap/extension-highlight": 3.23.2
|
||||||
"@tiptap/extension-image": 3.23.4
|
"@tiptap/extension-image": 3.23.2
|
||||||
"@tiptap/extension-link": ^3.23.4
|
"@tiptap/extension-link": ^3.23.2
|
||||||
"@tiptap/extension-placeholder": ^3.23.4
|
"@tiptap/extension-placeholder": ^3.23.2
|
||||||
"@tiptap/extension-table": 3.23.4
|
"@tiptap/extension-table": 3.23.2
|
||||||
"@tiptap/extension-table-cell": 3.23.4
|
"@tiptap/extension-table-cell": 3.23.2
|
||||||
"@tiptap/extension-table-header": 3.23.4
|
"@tiptap/extension-table-header": 3.23.2
|
||||||
"@tiptap/extension-table-row": 3.23.4
|
"@tiptap/extension-table-row": 3.23.2
|
||||||
"@tiptap/extension-task-item": 3.23.4
|
"@tiptap/extension-task-item": 3.23.2
|
||||||
"@tiptap/extension-task-list": 3.23.4
|
"@tiptap/extension-task-list": 3.23.2
|
||||||
"@tiptap/extension-text-align": 3.23.4
|
"@tiptap/extension-text-align": 3.23.2
|
||||||
"@tiptap/extension-text-style": 3.23.4
|
"@tiptap/extension-text-style": 3.23.2
|
||||||
"@tiptap/extension-underline": 3.23.4
|
"@tiptap/extension-underline": 3.23.2
|
||||||
"@tiptap/react": ^3.23.4
|
"@tiptap/react": ^3.23.2
|
||||||
"@tiptap/starter-kit": ^3.23.4
|
"@tiptap/starter-kit": ^3.23.2
|
||||||
"@trpc/client": ^11.17.0
|
"@trpc/client": ^11.17.0
|
||||||
"@trpc/next": ^11.17.0
|
"@trpc/next": ^11.17.0
|
||||||
"@trpc/react-query": ^11.17.0
|
"@trpc/react-query": ^11.17.0
|
||||||
"@trpc/server": ^11.17.0
|
"@trpc/server": ^11.17.0
|
||||||
"@trpc/tanstack-react-query": ^11.17.0
|
"@trpc/tanstack-react-query": ^11.17.0
|
||||||
"@turbo/gen": ^2.9.14
|
"@turbo/gen": ^2.9.12
|
||||||
"@types/adm-zip": 0.5.8
|
"@types/adm-zip": 0.5.8
|
||||||
"@types/bcrypt": 6.0.0
|
"@types/bcrypt": 6.0.0
|
||||||
"@types/better-sqlite3": 7.6.13
|
"@types/better-sqlite3": 7.6.13
|
||||||
@@ -101,7 +101,7 @@ catalog:
|
|||||||
adm-zip: 0.5.17
|
adm-zip: 0.5.17
|
||||||
babel-plugin-react-compiler: ^1.0.0
|
babel-plugin-react-compiler: ^1.0.0
|
||||||
bcrypt: ^6.0.0
|
bcrypt: ^6.0.0
|
||||||
better-sqlite3: ^12.10.0
|
better-sqlite3: ^12.9.0
|
||||||
chroma-js: ^3.2.0
|
chroma-js: ^3.2.0
|
||||||
clsx: ^2.1.1
|
clsx: ^2.1.1
|
||||||
concurrently: ^9.2.1
|
concurrently: ^9.2.1
|
||||||
@@ -121,9 +121,9 @@ catalog:
|
|||||||
drizzle-orm: ^0.45.2
|
drizzle-orm: ^0.45.2
|
||||||
drizzle-zod: ^0.8.3
|
drizzle-zod: ^0.8.3
|
||||||
esbuild: ^0.28.0
|
esbuild: ^0.28.0
|
||||||
eslint: ^10.4.0
|
eslint: ^10.3.0
|
||||||
eslint-config-prettier: ^10.1.8
|
eslint-config-prettier: ^10.1.8
|
||||||
eslint-config-turbo: ^2.9.14
|
eslint-config-turbo: ^2.9.12
|
||||||
eslint-plugin-import: ^2.32.0
|
eslint-plugin-import: ^2.32.0
|
||||||
eslint-plugin-jsx-a11y: ^6.10.2
|
eslint-plugin-jsx-a11y: ^6.10.2
|
||||||
eslint-plugin-react: ^7.37.5
|
eslint-plugin-react: ^7.37.5
|
||||||
@@ -134,7 +134,7 @@ catalog:
|
|||||||
glob: ^13.0.6
|
glob: ^13.0.6
|
||||||
ical.js: ^2.2.1
|
ical.js: ^2.2.1
|
||||||
ioredis: 5.10.1
|
ioredis: 5.10.1
|
||||||
isomorphic-dompurify: ^3.13.0
|
isomorphic-dompurify: ^3.12.0
|
||||||
jotai: ^2.20.0
|
jotai: ^2.20.0
|
||||||
jsdom: ^29.1.1
|
jsdom: ^29.1.1
|
||||||
json5: ^2.2.3
|
json5: ^2.2.3
|
||||||
@@ -171,9 +171,9 @@ catalog:
|
|||||||
testcontainers: ^11.14.0
|
testcontainers: ^11.14.0
|
||||||
timezones-ical-library: ^2.2.0
|
timezones-ical-library: ^2.2.0
|
||||||
trpc-to-openapi: ^3.2.0
|
trpc-to-openapi: ^3.2.0
|
||||||
tsdav: ^2.2.2
|
tsdav: ^2.2.1
|
||||||
tsx: 4.20.4
|
tsx: 4.20.4
|
||||||
turbo: ^2.9.14
|
turbo: ^2.9.12
|
||||||
typescript: ^5.9.3
|
typescript: ^5.9.3
|
||||||
typescript-eslint: ^8.58.2
|
typescript-eslint: ^8.58.2
|
||||||
undici: 7.24.6
|
undici: 7.24.6
|
||||||
@@ -193,5 +193,3 @@ minimumReleaseAge: 4320
|
|||||||
minimumReleaseAgeExclude:
|
minimumReleaseAgeExclude:
|
||||||
- next
|
- next
|
||||||
- "@next/*"
|
- "@next/*"
|
||||||
# Renovate security update: turbo@2.9.14
|
|
||||||
- turbo@2.9.14
|
|
||||||
+46
-11
@@ -1,19 +1,57 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://turborepo.org/schema.json",
|
"$schema": "https://turborepo.org/schema.json",
|
||||||
"remoteCache": { "signature": false },
|
"globalDependencies": ["**/.env"],
|
||||||
"globalEnv": ["CI", "NODE_ENV", "SKIP_ENV_VALIDATION"],
|
"globalEnv": [
|
||||||
|
"AUTH_LDAP_BASE",
|
||||||
|
"AUTH_LDAP_BIND_DN",
|
||||||
|
"AUTH_LDAP_BIND_PASSWORD",
|
||||||
|
"AUTH_LDAP_GROUP_CLASS",
|
||||||
|
"AUTH_LDAP_GROUP_FILTER_EXTRA_ARG",
|
||||||
|
"AUTH_LDAP_GROUP_MEMBER_ATTRIBUTE",
|
||||||
|
"AUTH_LDAP_GROUP_MEMBER_USER_ATTRIBUTE",
|
||||||
|
"AUTH_LDAP_SEARCH_SCOPE",
|
||||||
|
"AUTH_LDAP_URI",
|
||||||
|
"AUTH_OIDC_CLIENT_ID",
|
||||||
|
"AUTH_OIDC_CLIENT_NAME",
|
||||||
|
"AUTH_OIDC_CLIENT_SECRET",
|
||||||
|
"AUTH_OIDC_FORCE_USERINFO",
|
||||||
|
"AUTH_OIDC_ISSUER",
|
||||||
|
"AUTH_OIDC_SCOPE_OVERWRITE",
|
||||||
|
"AUTH_OIDC_GROUPS_ATTRIBUTE",
|
||||||
|
"AUTH_OIDC_NAME_ATTRIBUTE_OVERWRITE",
|
||||||
|
"AUTH_LDAP_USERNAME_ATTRIBUTE",
|
||||||
|
"AUTH_LDAP_USER_MAIL_ATTRIBUTE",
|
||||||
|
"AUTH_LDAP_USERNAME_FILTER_EXTRA_ARG",
|
||||||
|
"AUTH_OIDC_AUTO_LOGIN",
|
||||||
|
"AUTH_LOGOUT_REDIRECT_URL",
|
||||||
|
"AUTH_PROVIDERS",
|
||||||
|
"AUTH_SESSION_EXPIRY_TIME",
|
||||||
|
"CI",
|
||||||
|
"DISABLE_REDIS_LOGS",
|
||||||
|
"DB_URL",
|
||||||
|
"DB_HOST",
|
||||||
|
"DB_USER",
|
||||||
|
"DB_PASSWORD",
|
||||||
|
"DB_NAME",
|
||||||
|
"DB_PORT",
|
||||||
|
"DB_DRIVER",
|
||||||
|
"DOCKER_HOSTNAMES",
|
||||||
|
"DOCKER_PORTS",
|
||||||
|
"DOCKER_SOCKET_PATHS",
|
||||||
|
"NODE_ENV",
|
||||||
|
"PORT",
|
||||||
|
"LOCAL_CERTIFICATE_PATH",
|
||||||
|
"LOG_LEVEL",
|
||||||
|
"SECRET_ENCRYPTION_KEY",
|
||||||
|
"SKIP_ENV_VALIDATION"
|
||||||
|
],
|
||||||
"ui": "stream",
|
"ui": "stream",
|
||||||
"futureFlags": {
|
|
||||||
"affectedUsingTaskInputs": true
|
|
||||||
},
|
|
||||||
"tasks": {
|
"tasks": {
|
||||||
"topo": {
|
"topo": {
|
||||||
"dependsOn": ["^topo"],
|
"dependsOn": ["^topo"]
|
||||||
"inputs": ["package.json"]
|
|
||||||
},
|
},
|
||||||
"build": {
|
"build": {
|
||||||
"dependsOn": ["^build"],
|
"dependsOn": ["^build"],
|
||||||
"inputs": ["$TURBO_DEFAULT$", "!**/*.test.ts", "!**/*.test.tsx", "!**/*.spec.ts", "!**/__tests__/**"],
|
|
||||||
"outputs": [".next/**", "!.next/cache/**", "next-env.d.ts", ".output/**", ".vercel/output/**"]
|
"outputs": [".next/**", "!.next/cache/**", "next-env.d.ts", ".output/**", ".vercel/output/**"]
|
||||||
},
|
},
|
||||||
"dev": {
|
"dev": {
|
||||||
@@ -21,18 +59,15 @@
|
|||||||
"cache": false
|
"cache": false
|
||||||
},
|
},
|
||||||
"format": {
|
"format": {
|
||||||
"inputs": ["$TURBO_DEFAULT$"],
|
|
||||||
"outputs": ["node_modules/.cache/.prettiercache"],
|
"outputs": ["node_modules/.cache/.prettiercache"],
|
||||||
"outputLogs": "new-only"
|
"outputLogs": "new-only"
|
||||||
},
|
},
|
||||||
"lint": {
|
"lint": {
|
||||||
"dependsOn": ["^topo"],
|
"dependsOn": ["^topo"],
|
||||||
"inputs": ["$TURBO_DEFAULT$"],
|
|
||||||
"outputs": ["node_modules/.cache/.eslintcache"]
|
"outputs": ["node_modules/.cache/.eslintcache"]
|
||||||
},
|
},
|
||||||
"typecheck": {
|
"typecheck": {
|
||||||
"dependsOn": ["^topo"],
|
"dependsOn": ["^topo"],
|
||||||
"inputs": ["$TURBO_DEFAULT$"],
|
|
||||||
"outputs": ["node_modules/.cache/tsbuildinfo.json"]
|
"outputs": ["node_modules/.cache/tsbuildinfo.json"]
|
||||||
},
|
},
|
||||||
"clean": {
|
"clean": {
|
||||||
|
|||||||
Reference in new issue
Block a user