Skip to content

unable to invoke node js binary in sidecar  #8564

@abhijitpatil181171

Description

@abhijitpatil181171

Describe the bug

I have backend in node with sqlite . i have created binary of node using pkg but when i use this binary as sidecar and invoked in main.rs then i am getting error as shown img
image

Reproduction

No response

Expected behavior

main.rust should run backend binary so that my frontend can access backend api

Full tauri info output

{
  "$schema": "../node_modules/@tauri-apps/cli/schema.json",
  "build": {
    "beforeBuildCommand": "npm run build",
    "beforeDevCommand": "npm run start",
    "devPath": "http://localhost:3000",
    "distDir": "../build"
  },
  "package": {
    "productName": "web-application",
    "version": "0.1.0"
  },
  "tauri": {
    "allowlist": {
      "all": true,
      "shell": {
        "sidecar": true,
        "scope": [
          {
            "name": "D:\\Test-Json\\node-sqlite-backend\\server-win",
            "sidecar": true
          }
        ]
      }
    },

    "bundle": {
      "active": true,
      "category": "DeveloperTool",
      "copyright": "",
      "deb": {
        "depends": []
      },
      "externalBin": ["D:\\Test-Json\\node-sqlite-backend\\server-win"],
      "icon": [
        "icons/32x32.png",
        "icons/128x128.png",
        "icons/128x128@2x.png",
        "icons/icon.icns",
        "icons/icon.ico"
      ],
      "identifier": "com.yourdomain.yourapp",
      "longDescription": "",
      "macOS": {
        "entitlements": null,
        "exceptionDomain": "",
        "frameworks": [],
        "providerShortName": null,
        "signingIdentity": null
      },
      "resources": [],
      "shortDescription": "",
      "targets": "all",
      "windows": {
        "certificateThumbprint": null,
        "digestAlgorithm": "sha256",
        "timestampUrl": ""
      }
    },
    "security": {
      "dangerousDisableAssetCspModification": false,
      "dangerousRemoteDomainIpcAccess": [],
      "dangerousUseHttpScheme": true,
      "freezePrototype": false
    },
    "updater": {
      "active": false
    },
    "windows": [
      {
        "fullscreen": false,
        "height": 800,
        "resizable": true,
        "title": "USER ENTRY",
        "width": 920
      }
    ]
  }
}
this is my tauri.config.json

Stack trace

No response

Additional context

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions