S
S
Shurik2021-05-31 02:35:25
Docker
Shurik, 2021-05-31 02:35:25

Why is there a php error on docker-compose build?

Hello. I reinstalled Ubuntu OS and some problems with docker started. When trying to build a project, a php error occurs:
in one of the projects:

ERROR: Service 'php' failed to build: The command '/bin/sh -c composer global require --optimize-autoloader         "hirak/prestissimo:${VERSION_PRESTISSIMO_PLUGIN}" &&     composer global dumpautoload --optimize &&     composer clear-cache' returned a non-zero code: 1


in a different:
ERROR: Service 'php' failed to build: The command '/bin/sh -c apt-get update && apt-get install -y         libfreetype6-dev         libjpeg62-turbo-dev         libmcrypt-dev         libpng-dev         libicu-dev         libpq-dev         libxpm-dev         libvpx-dev     && pecl install xdebug     && docker-php-ext-enable xdebug     && docker-php-ext-install -j$(nproc) mcrypt     && docker-php-ext-install -j$(nproc) gd     && docker-php-ext-install -j$(nproc) intl     && docker-php-ext-install -j$(nproc) zip     && docker-php-ext-install -j$(nproc) pgsql     && docker-php-ext-install -j$(nproc) pdo_pgsql     && docker-php-ext-install -j$(nproc) exif     && docker-php-ext-configure gd         --with-freetype-dir=/usr/include/         --with-jpeg-dir=/usr/include/         --with-xpm-dir=/usr/lib/x86_64-linux-gnu/         --with-vpx-dir=/usr/lib/x86_64-linux-gnu/' returned a non-zero code: 1


With what it can be connected? The php system is now 7.4. I tried to change to others - it did not help, as well as changing the version of composer.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Shurik, 2021-05-31
@svisch

Decided as follows:
Deleted the following lines from the Dockerfile. In the console, it was on this package that I cursed. I don’t know what he is responsible for, but without him everything started up fine

# Install composer plugins
RUN composer global require --optimize-autoloader \
        "hirak/prestissimo:${VERSION_PRESTISSIMO_PLUGIN}" && \
    composer global dumpautoload --optimize && \
    composer clear-cache

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question