link-stack/apps/link/next.config.js

50 lines
1.1 KiB
JavaScript
Raw Normal View History

/** @type {import('next').NextConfig} */
const nextConfig = {
poweredByHeader: false,
2024-05-14 09:40:58 +02:00
transpilePackages: [
2024-06-05 08:52:41 +02:00
"@link-stack/leafcutter-ui",
"@link-stack/opensearch-common",
"@link-stack/ui",
"@link-stack/bridge-common",
"@link-stack/bridge-ui",
"mui-chips-input",
2024-05-14 09:40:58 +02:00
],
headers: async () => {
return [
{
source: "/((?!zammad).*)",
headers: [
{
key: "Strict-Transport-Security",
value: "max-age=63072000; includeSubDomains; preload",
},
{
key: "X-Frame-Options",
value: "DENY",
},
{
key: "X-Content-Type-Options",
value: "nosniff",
},
],
},
];
2023-05-25 12:37:14 +00:00
},
rewrites: async () => {
return {
beforeFiles: [
{
source: "/api/v1/:path*",
destination: `${process.env.ZAMMAD_URL ?? "http://zammad-nginx:8080"}/api/v1/:path*`,
},
{
source: "/ws",
destination: `${process.env.ZAMMAD_URL ?? "http://zammad-nginx:8080"}/ws`,
},
],
};
},
2022-12-02 10:55:56 +00:00
};
2024-05-14 09:40:58 +02:00
export default nextConfig;