How to convert interactive script to run on headless server
Posted: Thu Feb 13, 2025 9:52 pm
qcad-3.31.2-pro-linux-qt5.14-x86_64
interactive target ubuntu 24.04 desktop
headless target ubuntu 24.04 server
I have written a script that functions either interactively if qcad is started without a user argument --path= on the command line or "automatically" if the --path argument is present.
qcad -platform offscreen -no-gui -exec File/PRformalDwg/PRformalDwg.js --path="\$panelRightMntDir/Development/panelizerOut"
Is a command line that works on ubuntu 24.04 desktop. The debug statements at startup prior to the user script starting are:
mark@Z790-AORUS-ELITE-AX:~/opt/qcad-3.31.2-pro-linux-qt5.14-x86_64/scripts$ qcad -platform offscreen -no-gui -exec File/PRformalDwg/PRformalDwg.js --path="\$panelRightMntDir/Development/panelizerOut"
QCAD version 3.31.2
11:37:35: Debug: loading plugins...
11:37:35: Debug: RHelpPlugin::init
11:37:35: Debug: RPolygonPlugin::init
11:37:35: Debug: RProScriptsPlugin::init
11:37:35: Debug: RProxiesPlugin::init
11:37:35: Debug: RTracePlugin::init
11:37:35: Debug: RDwgPlugin::init
11:37:35: Debug: loading static plugins...
11:37:35: Debug: LayerListPro.init
11:37:35: Debug: loading plugins...
11:37:35: Debug: loading static plugins...
Warning: This plugin does not support propagateSizeHints()
11:37:35: Debug: loading plugins...
11:37:35: Debug: loading static plugins...
11:37:35: Debug: openFiles: -allow-multiple-instances,-no-gui,-exec,File/PRformalDwg/PRformalDwg.js,--path=$panelRightMntDir/Development/panelizerOut
However, that same command line executed on ubuntu 24.04 server hangs after the Warning: This plugin does not support propagateSizeHints() statement. The application hangs before the "loading plugins..." statement found in ../sourceCode/src/core/RPluginLoader.cpp: qDebug() << "loading plugins...";
Since my script does not even get a chance to run, it seems I need to add more to the server environment to make qcad happy.
Suggestions?
Thanks.
interactive target ubuntu 24.04 desktop
headless target ubuntu 24.04 server
I have written a script that functions either interactively if qcad is started without a user argument --path= on the command line or "automatically" if the --path argument is present.
qcad -platform offscreen -no-gui -exec File/PRformalDwg/PRformalDwg.js --path="\$panelRightMntDir/Development/panelizerOut"
Is a command line that works on ubuntu 24.04 desktop. The debug statements at startup prior to the user script starting are:
mark@Z790-AORUS-ELITE-AX:~/opt/qcad-3.31.2-pro-linux-qt5.14-x86_64/scripts$ qcad -platform offscreen -no-gui -exec File/PRformalDwg/PRformalDwg.js --path="\$panelRightMntDir/Development/panelizerOut"
QCAD version 3.31.2
11:37:35: Debug: loading plugins...
11:37:35: Debug: RHelpPlugin::init
11:37:35: Debug: RPolygonPlugin::init
11:37:35: Debug: RProScriptsPlugin::init
11:37:35: Debug: RProxiesPlugin::init
11:37:35: Debug: RTracePlugin::init
11:37:35: Debug: RDwgPlugin::init
11:37:35: Debug: loading static plugins...
11:37:35: Debug: LayerListPro.init
11:37:35: Debug: loading plugins...
11:37:35: Debug: loading static plugins...
Warning: This plugin does not support propagateSizeHints()
11:37:35: Debug: loading plugins...
11:37:35: Debug: loading static plugins...
11:37:35: Debug: openFiles: -allow-multiple-instances,-no-gui,-exec,File/PRformalDwg/PRformalDwg.js,--path=$panelRightMntDir/Development/panelizerOut
However, that same command line executed on ubuntu 24.04 server hangs after the Warning: This plugin does not support propagateSizeHints() statement. The application hangs before the "loading plugins..." statement found in ../sourceCode/src/core/RPluginLoader.cpp: qDebug() << "loading plugins...";
Since my script does not even get a chance to run, it seems I need to add more to the server environment to make qcad happy.
Suggestions?
Thanks.