pnpm / pnpm.io

pnpm's website
https://pnpm.io
MIT License
220 stars 491 forks source link

[doc] installation script titled "On Alpine Linux" should be titled "In docker container and Dockerfile" #477

Closed ZYinMD closed 8 months ago

ZYinMD commented 11 months ago

Contribution

Describe the user story

In doc > Introduction > Installation, the POSIX installation script doesn't work in docker container or Dockerfile, not just in Alpine, but in other type of images too.

For instance:

docker run -it --rm node:latest bash
wget -qO- https://get.pnpm.io/install.sh | sh - #  ERR_PNPM_UNKNOWN_SHELL
docker run -it --rm python:latest bash
wget -qO- https://get.pnpm.io/install.sh | sh - #  ERR_PNPM_UNKNOWN_SHELL
docker run -it --rm ubuntu:latest
apt update && apt install -y wget
wget -qO- https://get.pnpm.io/install.sh | sh - #  ERR_PNPM_UNKNOWN_SHELL

Describe the solution you'd like

The On Alpine Linux section title should be named "In docker container and Dockerfile".

Describe the drawbacks of your solution

Maybe there are a small number of people who are really using the Alpine Linux, but not with docker? But (1) there can't be many (2) the POSIX script might just work for them (3) the benefit outweighs risk

Describe alternatives you've considered

Better handle the ERR_PNPM_UNKNOWN_SHELL error in the POSIX script.

KSXGitHub commented 11 months ago

Mentioning both "docker container" and "dockerfile" would be redundant. Just one is sufficient.

Anyway, just make a PR and @zkochan will discuss it with you further.