Articles in this section

How to change in the PHP Composer extension the path of the composer.json file?

kb: fixed Plesk for Linux kb: technical Plesk Obsidian for Windows ABT: Group A

Applicable to:

  • Plesk for Linux
  • Plesk for Windows

Question

How to change the path of the composer.json file in the PHP Composer extension?

Answer

Note: The feature has been implemented in the scope of the #EXTPHPCOMP-71 feature request and it'ss available since 1.0.2 version of PHP Composer. Make sure that the PHP Composer extension is up to date: Install the latest updates for extensions

  1. Log in to Plesk GUI
  2. Go to Domains > example.com > PHP Composer > Click [change] > Select the path of the application containing the composer.json file > Click Change folder
For composer.json files added after the initial scan

Linux:

  1. Connect to the server via SSH
  2. Run command below in the CLI

    # plesk ext composer --application -register -domain example.com -path httpdocs/one.example.com/

  3. Go to Domains > example.com > PHP Composer Extension > click "Change".

Windows:

  1. Connect to the server via RDP
  2. Run command below in the CLI

    C:\> plesk ext composer --application -register -domain example.com -path httpdocs/one.example.com/

  3. Go to Domains > example.com > PHP Composer Extension > click "Change".
Was this article helpful?

Comments

2 comments
Date Votes
  • Hi Stefan

    How can I remove a path from composer?

    0
  • Due to #EXTPLESK-4427 it can't be done for now.

    Hence you can instead remove/edit application in `Applications` table of /usr/local/psa/var/modules/composer/composer.sqlite3

    You can follow https://docs.plesk.com/release-notes/obsidian/change-log/ to get informed once #EXTPLESK-4427 is resolved.

    0

Please sign in to leave a comment.