Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


    Cloudron Forum

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular

    Solved Error while update npm-package

    App Packaging & Development
    3
    4
    384
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      roru2k20 last edited by

      Good morning,

      on my WSL-Ubuntu also on my VPS I get an error while I would like to update an app with cloudron-cli.

      It said to me, that I should update the npm package of cloudron-cli

      sudo npm install -g cloudron@4.13.1
      
      changed 121 packages, and audited 122 packages in 4s
      
      13 packages are looking for funding
        run `npm fund` for details
      
      2 vulnerabilities (1 moderate, 1 high)
      
      To address issues that do not require attention, run:
        npm audit fix
      
      Some issues need review, and may require choosing
      a different dependency.
      
      Run `npm audit` for details.
      
      ----
      sudo npm audit fix --force
      ----
      
      npm WARN using --force Recommended protections disabled.
      npm ERR! code ENOLOCK
      npm ERR! audit This command requires an existing lockfile.
      npm ERR! audit Try creating one first with: npm i --package-lock-only
      npm ERR! audit Original error: loadVirtual requires existing shrinkwrap file
      
      npm ERR! A complete log of this run can be found in:
      npm ERR!     /root/.npm/_logs/2022-01-22T06_06_38_189Z-debug-0.log
      

      I have no clue what can I do to solve this problem.

      nebulon 1 Reply Last reply Reply Quote 0
      • nebulon
        nebulon Staff @roru2k20 last edited by

        @roru2k20 are you by any chance running the npm install command withing a repository which contains a package.json or so?

        Also which nodejs and npm versions are you using?

        Further it is not clear to me, if the install or the audit fix fails. The latter should not be run when installing the cli, this is something you would run as a developer developing the package. We are updating the cli package as we see fit, not all automatic security warnings issued by npm are relevant, so no worries.

        mehdi R 2 Replies Last reply Reply Quote 0
        • mehdi
          mehdi App Dev @nebulon last edited by

          @nebulon said in Error while update npm-package:

          not all automatic security warnings issued by npm are relevant

          I would even say : basically no automatic security warning issued by npm is relevant...

          1 Reply Last reply Reply Quote 0
          • R
            roru2k20 @nebulon last edited by

            Thanks @mehdi and @nebulon

            My problem solved by deleting the package-lock.json. After that I can update this app and all works good.

            Thank you very much.

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Powered by NodeBB