Skip to content

sudo pkgm install doesn't work #68

Open

Description

@fengjianyun

pkgx version : 2.7.0
pkgm version : 0.11.1
OS : WSL 2, Ubutun 20.04.6

pkgm install without sudo works, but with sudo I have this error message:

$ sudo pkgm install node
sudo: unable to execute /root/.pkgx/pkgx.sh/v2.7.0/bin/pkgx: Permission denied

But I can run this

$ sudo /root/.pkgx/pkgx.sh/v2.7.0/bin/pkgx -v
pkgx 2.7.0

Activity

  1. tannevaled commented on Apr 29, 2026

    @tannevaled
    Contributor

    is there any progress on this?

    OS : Fresh Ubuntu 24.04 Cloud Image

    $ sudo pkgm install gitlab-runner
    sudo: unable to execute /root/.pkgx/pkgx.sh/v2.10.3/bin/pkgx: Permission denied
    $ sudo /root/.pkgx/pkgx.sh/v2.10.3/bin/pkgx -v
    pkgx 2.10.3
  2. jhheider commented on Apr 29, 2026

    @jhheider
    Contributor

    my recollection is that pkgm will invoke sudo itself. i'll take a look.

  3. tannevaled commented on May 4, 2026

    @tannevaled
    Contributor

    just proposed a PR to fix this

  4. tannevaled commented on May 12, 2026

    @tannevaled
    Contributor

    @jhheider can you take a look on this please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions