CADViewer Conversion Server Technical Documentation

Configuration Options

Server Configuration (CADViewer_config.json)

The CADViewer Conversion Server is primarily controlled through the CADViewer_config.json file. This file contains all paths, port numbers, and core behavioral settings for the Node.js backend.

Automatic Platform Detection

By default, the server is configured to automatically detect your operating system (Windows or Linux) and configure the paths accordingly:

  • autodetect_platform: Set to true to let the server automatically determine if it is running on Windows or Linux.
  • autodetect_location: Set to true to automatically set up all internal folder paths (e.g., converters, temporary files, uploads).

If you are running in a highly customized environment, you can set both to false and manually provide the exact absolute paths below.

Core Server Settings

  • ServerPort: The port the Node.js server listens on (default: 3000).
  • ServerUrl: The fully qualified URL of the server (e.g., http://localhost:3000).
  • ServerFrontEndUrl: The URL of your front-end application. If specified, this allows for strict CORS policies.
  • cvjs_debug: Set to true to enable verbose logging in the server console for debugging file conversions and API calls.

File and Converter Locations

  • ServerLocation: The root path of the conversion server script.
  • fileLocation: The directory where temporary and uploaded files are stored during conversion (e.g., /converters/files/).
  • converterLocation: The path to the AutoXchange binaries (/converters/autoxchange/).
  • fontLocation: The path where your CAD fonts (.shx, .ttf) are stored so the converter can embed them into the SVG/PDF outputs.

Docker Configuration

If you are running the server via Docker, the internal networking behaves differently. You must bind the server to 0.0.0.0 rather than localhost.

The repository provides a pre-configured template called CADViewer_config-docker.json. Simply rename it to CADViewer_config.json before building your container. The key changes are:

"ServerUrl" : "http://0.0.0.0:3000",
"fileLocationUrl" : "http://0.0.0.0:3000/converters/files/",
"callbackMethod_gatewayUrl_flag" : true,
"callbackMethod_gatewayUrl" : "http://localhost:3000"

(Note: callbackMethod_gatewayUrl should represent the external facing URL that clients use to reach the Docker container).

Last updated on 3 Sep 2026
Published on 3 Sep 2026