fix: Docker build in CI (#8312)

* Fix Docker build CI
* Bump nginx-alpine version to 1.27
This commit is contained in:
Márk Tolmács 2024-08-06 13:21:20 +02:00 committed by GitHub
parent b87925d253
commit 8d530cf102
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 10 additions and 10 deletions

View File

@ -8,6 +8,7 @@
!package.json
!public/
!packages/
!scripts/
!tsconfig.json
!yarn.lock

View File

@ -12,7 +12,7 @@ ARG NODE_ENV=production
RUN yarn build:app:docker
FROM nginx:1.24-alpine
FROM nginx:1.27-alpine
COPY --from=build /opt/node_app/excalidraw-app/build /usr/share/nginx/html

View File

@ -26,10 +26,10 @@ export default defineConfig({
assetFileNames(chunkInfo) {
if (chunkInfo?.name?.endsWith(".woff2")) {
// put on root so we are flexible about the CDN path
return '[name]-[hash][extname]';
return "[name]-[hash][extname]";
}
return 'assets/[name]-[hash][extname]';
return "assets/[name]-[hash][extname]";
},
// Creating separate chunk for locales except for en and percentages.json so they
// can be cached at runtime and not merged with
@ -44,7 +44,7 @@ export default defineConfig({
// Taking the substring after "locales/"
return `locales/${id.substring(index + 8)}`;
}
}
},
},
},
sourcemap: true,

View File

@ -58,7 +58,7 @@ module.exports.woff2BrowserPlugin = () => {
style: normal;
display: swap;
}
@font-face {
font-family: "Assistant";
src: url(${OSS_FONTS_CDN}Assistant-Medium-DrcxCXg3.woff2)
@ -68,7 +68,7 @@ module.exports.woff2BrowserPlugin = () => {
style: normal;
display: swap;
}
@font-face {
font-family: "Assistant";
src: url(${OSS_FONTS_CDN}Assistant-SemiBold-SCI4bEL9.woff2)
@ -78,7 +78,7 @@ module.exports.woff2BrowserPlugin = () => {
style: normal;
display: swap;
}
@font-face {
font-family: "Assistant";
src: url(${OSS_FONTS_CDN}Assistant-Bold-gm-uSS1B.woff2)

View File

@ -2,9 +2,8 @@ import { defineConfig } from "vitest/config";
import { woff2BrowserPlugin } from "./scripts/woff2/woff2-vite-plugins";
export default defineConfig({
plugins: [
woff2BrowserPlugin(),
],
// @ts-ignore
plugins: [woff2BrowserPlugin()],
test: {
setupFiles: ["./setupTests.ts"],
globals: true,