mirror of
https://github.com/9technologygroup/patchmon.net.git
synced 2025-11-14 19:05:44 +00:00
feat: add canvas runtime dependencies to frontend Docker image for Trianglify support
This commit is contained in:
@@ -39,6 +39,9 @@ RUN npm run build
|
||||
# Production stage
|
||||
FROM nginxinc/nginx-unprivileged:alpine
|
||||
|
||||
# Install runtime dependencies for canvas
|
||||
RUN apk add --no-cache cairo pango jpeg libpng giflib
|
||||
|
||||
ENV BACKEND_HOST=backend \
|
||||
BACKEND_PORT=3001
|
||||
|
||||
|
||||
@@ -265,11 +265,8 @@ const Layout = ({ children }) => {
|
||||
pattern.toCanvas(bgCanvasRef.current);
|
||||
}
|
||||
} catch (error) {
|
||||
// Canvas/trianglify not available, skip background generation silently
|
||||
// Only log in development for debugging
|
||||
if (import.meta.env.DEV) {
|
||||
console.warn("Could not generate Trianglify background:", error);
|
||||
}
|
||||
// Canvas/trianglify not available, skip background generation
|
||||
console.warn("Could not generate Trianglify background:", error);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -81,11 +81,8 @@ const Login = () => {
|
||||
pattern.toCanvas(canvasRef.current);
|
||||
}
|
||||
} catch (error) {
|
||||
// Canvas/trianglify not available, skip background generation silently
|
||||
// Only log in development for debugging
|
||||
if (import.meta.env.DEV) {
|
||||
console.warn("Could not generate Trianglify background:", error);
|
||||
}
|
||||
// Canvas/trianglify not available, skip background generation
|
||||
console.warn("Could not generate Trianglify background:", error);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user