-
Hi,
I have noticed that Composer comes pre-installed with the Cloudron LAMP stack. If I change into a terminal, I can use it by executing "composer". However, if I run the following command:
root@5585a070-9420-4f84-bd98-5198b471ffb4:/app/data/public# composer require drush/drush Cannot create cache directory /root/.composer/cache/repo/https---packagist.org/, or directory is not writable. Proceeding without cache Cannot create cache directory /root/.composer/cache/files/, or directory is not writable. Proceeding without cache Do not run Composer as root/super user! See https://
I see that Composer is not able to create its cache. Also it gets killed, when I try to require a package:
root@5585a070-9420-4f84-bd98-5198b471ffb4:/app/data/public# composer require drush/drush Cannot create cache directory /root/.composer/cache/repo/https---packagist.org/, or directory is not writable. Proceeding without cache Cannot create cache directory /root/.composer/cache/files/, or directory is not writable. Proceeding without cache Do not run Composer as root/super user! See https://getcomposer.org/root for details Using version ^9.5 for drush/drush ./composer.json has been updated Cannot create cache directory /root/.composer/cache/repo/https---packagist.org/, or directory is not writable. Proceeding without cache Cannot create cache directory /root/.composer/cache/files/, or directory is not writable. Proceeding without cache Loading composer repositories with package information Updating dependencies (including require-dev) Killed root@5585a070-9420-4f84-bd98-5198b471ffb4:/app/data/public#
What am I doing wrong? Is there an error on your end? Could not find any info about Composer usage. I need Composer for my PHP app.
Kind regards
Peter