diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile index 099f5a45090..589256ae0fe 100644 --- a/.devcontainer/Dockerfile +++ b/.devcontainer/Dockerfile @@ -11,5 +11,8 @@ RUN echo node ALL=\(root\) NOPASSWD:ALL > /etc/sudoers.d/node && chmod 0440 /etc RUN mkdir /workspaces && chown node:node /workspaces RUN corepack enable +ENV PNPM_HOME=/home/node/.local/share/pnpm +ENV PATH=$PNPM_HOME/bin:$PATH + USER node -RUN mkdir -p ~/.pnpm-store && pnpm config set store-dir ~/.pnpm-store --global +RUN mkdir -p $PNPM_HOME ~/.pnpm-store && pnpm config set store-dir ~/.pnpm-store --global diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 7b7a1e89d2d..dc0f5976ad3 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -9,7 +9,7 @@ "type=bind,source=${localEnv:HOME}/.n8n,target=/home/node/.n8n,consistency=cached" ], "forwardPorts": [8080, 5678], - "postCreateCommand": "corepack prepare --activate && pnpm install", + "postCreateCommand": "corepack install && pnpm install", "postAttachCommand": "pnpm build", "customizations": { "codespaces": {