Skip to content

[rush] Provide a lightweight "rush deploy" mode that does not require any symlinks #2045

@dpolivy

Description

@dpolivy

Please prefix the issue title with the project name i.e. [rush], [api-extractor] etc.

Is this a feature or a bug?

  • Feature
  • Bug

Please describe the actual behavior.

rush deploy is great, however it has a fundamental incompatibility with deployments that don't support symlinks, such as Azure App Service's Run from Package. In this scenario, zipping up the deployment directory creates copies of all the files referenced by symlinks, but it means that only the main dependencies of each app are able to be resolved -- any dependencies of those dependencies cannot be resolved, as that is dependent on resolving based on the symlink'ed location of the module. Therefore, apps that are packaged directly are unable to run without symlinks. Unfortunately, the Run from Package feature does not support TAR files (which do support symlinks).

What is the expected behavior?

I would expect rush deploy to be able to produce output that could be deployed without relying on the symlinks. One thought here is that the common\temp\node_modules\.pnpm\node_modules\ directory could be symlinked/located in the root, which might solve the problem, although in a ZIP of the deploy directory would lead to quite a bit of duplication and bloat. If there were a way to just have all of the required node modules for production (including local projects) stored in a flat structure in the root of the deploy folder, that would be ideal, as then there would be only a single copy of each module in the deployment.

If this is a bug, please provide the tool version, Node.js version, and OS.

  • Tool: rush
  • Tool Version: 5.30.0
  • Node Version: 12.18.1
    • Is this a LTS version? Yes
    • Have you tested on a LTS version?
  • OS: Windows 10

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementThe issue is asking for a new feature or design changeneeds designThe next step is for someone to propose the details of an approach for solving the problem

    Type

    No type

    Projects

    Status

    Needs triage

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions