feat: Carbone Word template integration with DOCX merge and LibreOffice PDF conversion
This commit is contained in:
24
renderer/carbone-server.js
Normal file
24
renderer/carbone-server.js
Normal file
@@ -0,0 +1,24 @@
|
||||
/**
|
||||
* Carbone Express Server - Standalone microservice
|
||||
* Runs on port 8771 alongside the FastAPI app on 8770
|
||||
*/
|
||||
const express = require('express');
|
||||
const cors = require('cors');
|
||||
const path = require('path');
|
||||
const { router } = require('./carbone-service');
|
||||
|
||||
const app = express();
|
||||
const PORT = 8771;
|
||||
|
||||
app.use(cors());
|
||||
app.use(express.json({ limit: '50mb' }));
|
||||
|
||||
// Mount Carbone routes
|
||||
app.use('/api/carbone', router);
|
||||
|
||||
// Health check
|
||||
app.get('/health', (req, res) => res.json({ status: 'ok', service: 'carbone' }));
|
||||
|
||||
app.listen(PORT, '0.0.0.0', () => {
|
||||
console.log(`Carbone service running on http://0.0.0.0:${PORT}`);
|
||||
});
|
||||
Reference in New Issue
Block a user