Custom config launch n8n

Hello,

I use n8n-node-env(I need to create custom node) and n8n dockerfile and docker-compose for launch my project, my files:

Dockerfile.local:

FROM node:14.17.3-buster-slim

#RUN yarn global add n8n-node-dev
#RUN yarn global add n8n

#ADD package.json /app/

WORKDIR /app/

#RUN yarn install

EXPOSE 5678

CMD bash

package.json:

{
  "name": "n8n",
  "version": "0.0.1",
  "scripts": {
    "start": "n8n-node-dev build && n8n"
  },
  "dependencies": {
    "@types/express": "^4.17.13",
    "@types/node": "^16.4.13",
    "n8n": "^0.137.0",
    "n8n-core": "^0.79.0",
    "n8n-node-dev": "^0.22.0",
    "n8n-workflow": "^0.64.0",
    "nodelinter": "^0.1.12"
  },
  "devDependencies": {
    "@types/request": "^2.48.7",
    "@types/request-promise-native": "^1.0.18"
  }
}

docker-compose.yml:

version: "2"

services:
  n8n:
    image: something-unstable-20
    restart: always
    ports:
      - 5678:5678
    volumes:
      - ./:/app/
      - /app/node_modules/

    command: bash -c "yarn install && yarn start"

When I launch project I got this error:

n8n_1  | GOT ERROR: "dir option must be relative to "/tmp", found "/app"."
n8n_1  | ====================================
n8n_1  | Error: dir option must be relative to "/tmp", found "/app".
n8n_1  |     at _assertIsRelative (/app/node_modules/tmp/lib/tmp.js:599:13)
n8n_1  |     at _assertAndSanitizeOptions (/app/node_modules/tmp/lib/tmp.js:513:5)
n8n_1  |     at tmpName (/app/node_modules/tmp/lib/tmp.js:65:5)
n8n_1  |     at Object.file (/app/node_modules/tmp/lib/tmp.js:133:3)
n8n_1  |     at /app/node_modules/tmp-promise/index.js:9:7
n8n_1  |     at internal/util.js:308:30
n8n_1  |     at new Promise (<anonymous>)
n8n_1  |     at internal/util.js:307:12
n8n_1  |     at Object.module.exports.file (/app/node_modules/tmp-promise/index.js:13:42)
n8n_1  |     at createCustomTsconfig (/app/node_modules/n8n-node-dev/dist/src/Build.js:23:55)
n8n_1  | Initializing n8n process

The project is launch but I don’t recover custom-nodes (because this error above), what is wrong ? thanks

The same happened to me, but I have not had the chance to look at it. Also, it seems a community member sent a PR finding this issue.

allright, thanks

Will keep you posted. Thanks for making us aware of this.