yii2-app-advanced icon indicating copy to clipboard operation
yii2-app-advanced copied to clipboard

docker-compose run --rm backend composer install

Open WeeSee opened this issue 4 years ago • 2 comments

What steps will reproduce the problem?

Install yii2-app-advanced following the instructions "Installing using Docker" Run step docker-compose run --rm backend composer install

What's expected?

Get composer install running - without warnings

What do you get instead?

composer is complaining:

Warning from https://repo.packagist.org: You are using an outdated version of Composer. Composer 2.0 is now available and you should upgrade. See https://getcomposer.org/2

Additional info

Q A
Yii version Yii2
PHP version
Operating system Docker

WeeSee avatar Jan 17 '21 16:01 WeeSee

see also https://github.com/yiisoft/yii2-docker/issues/116#issuecomment-754577262

schmunk42 avatar Jan 18 '21 15:01 schmunk42

I fixed it by adding RUN composer self-update --2 to the Dockerfile

anasjaghoub avatar Feb 02 '21 15:02 anasjaghoub

@schmunk42 is it still an issue?

samdark avatar Aug 18 '22 21:08 samdark

No, all images should have composer 2.

> docker run -it yiisoftware/yii2-php:7.4-apache bash
usermod: no changes
        _ _  __                                             _
       (_|_)/ _|                                           | |
  _   _ _ _| |_ _ __ __ _ _ __ ___   _____      _____  _ __| | __
 | | | | | |  _| '__/ _` | '_ ` _ \ / _ \ \ /\ / / _ \| '__| |/ /
 | |_| | | | | | | | (_| | | | | | |  __/\ V  V / (_) | |  |   <
  \__, |_|_|_| |_|  \__,_|_| |_| |_|\___| \_/\_/ \___/|_|  |_|\_\
   __/ |
  |___/

PHP version: 7.4.29
root@70023634d094:/app# composer -v
   ______
  / ____/___  ____ ___  ____  ____  ________  _____
 / /   / __ \/ __ `__ \/ __ \/ __ \/ ___/ _ \/ ___/
/ /___/ /_/ / / / / / / /_/ / /_/ (__  )  __/ /
\____/\____/_/ /_/ /_/ .___/\____/____/\___/_/
                    /_/
Composer version 2.3.5 2022-04-13 16:43:00

schmunk42 avatar Aug 19 '22 11:08 schmunk42