fix: mettre à jour la configuration de wrangler et ajuster les scripts de build et de déploiement

This commit is contained in:
2025-12-18 20:30:15 +01:00
parent fbe223b50c
commit 7206a17a6a
4 changed files with 10 additions and 39 deletions

View File

@@ -104,13 +104,7 @@ export default defineNuxtConfig({
},
nitro: {
preset: 'cloudflare_module',
prerender: {
routes: ['/'],
crawlLinks: true,
ignore: ['/__nuxt_content', '/api/_content', '/studio']
}
preset: 'cloudflare_pages',
},
runtimeConfig: {

View File

@@ -2,12 +2,12 @@
"name": "artsite",
"private": true,
"scripts": {
"build": "nuxi build --preset cloudflare_module",
"build": "nuxi build",
"dev": "nuxi dev",
"preview": "bun run build && wrangler dev",
"postinstall": "nuxt prepare",
"lint": "eslint .",
"deploy": "bun run build && wrangler deploy",
"deploy": "bun run cf-typegen && bun run build && wrangler pages deploy .output/public",
"cf-typegen": "wrangler types"
},
"dependencies": {
@@ -34,6 +34,6 @@
"@vueuse/nuxt": "14.1.0",
"eslint": "9.39.2",
"typescript": "^5.9.3",
"wrangler": "4.55.0"
"wrangler": "4.56.0"
}
}

View File

@@ -1,10 +1,7 @@
/* eslint-disable */
// Generated by Wrangler by running `wrangler types` (hash: 62d6edfcbe10d837218cb1a518a9ad0a)
// Generated by Wrangler by running `wrangler types` (hash: 889e96b9a6e7cd90ad202f69774b6cc7)
// Runtime types generated with workerd@1.20251213.0 2025-12-13 nodejs_compat
declare namespace Cloudflare {
interface GlobalProps {
mainModule: typeof import("./.output/server/index");
}
interface Env {
CACHE: KVNamespace;
NUXT_PUBLIC_I18N_BASE_URL: string;
@@ -12,7 +9,6 @@ declare namespace Cloudflare {
STUDIO_GITHUB_CLIENT_ID: string;
STUDIO_GITHUB_CLIENT_SECRET: string;
DB: D1Database;
ASSETS: Fetcher;
}
}
interface Env extends Cloudflare.Env {}
@@ -8603,7 +8599,7 @@ type AIGatewayHeaders = {
[key: string]: string | number | boolean | object;
};
type AIGatewayUniversalRequest = {
provider: AIGatewayProviders | string;
provider: AIGatewayProviders | string; // eslint-disable-line
endpoint: string;
headers: Partial<AIGatewayHeaders>;
query: unknown;
@@ -8619,7 +8615,7 @@ declare abstract class AiGateway {
gateway?: UniversalGatewayOptions;
extraHeaders?: object;
}): Promise<Response>;
getUrl(provider?: AIGatewayProviders | string): Promise<string>;
getUrl(provider?: AIGatewayProviders | string): Promise<string>; // eslint-disable-line
}
interface AutoRAGInternalError extends Error {
}

View File

@@ -5,14 +5,9 @@
"compatibility_flags": [
"nodejs_compat"
],
"pages_build_output_dir": ".output/public",
"routes": [
{
"pattern": "v2.arthurdanjou.fr",
"zone_name": "arthurdanjou.fr",
"custom_domain": true
}
],
"placement": {
"mode": "smart"
},
"d1_databases": [
{
"binding": "DB",
@@ -25,18 +20,4 @@
"id": "f0766ace1d24423ba6e5cac4fb8f2054"
}
],
"observability": {
"enabled": true,
"logs": {
"enabled": true,
"head_sampling_rate": 1,
"persist": true,
"invocation_logs": true
},
"traces": {
"enabled": true,
"head_sampling_rate": 1,
"persist": true
}
}
}