R
R
Romi2022-02-13 15:34:39
Docker
Romi, 2022-02-13 15:34:39

Laradock: "docker-compose build workspace" - failed - what to do?

Today I decided to try PHP version 8 in the project :-) I cloned Laradock from GitHub into the folder of the new project, launched it, and, unexpectedly, php -vinside the workspace I got 7.4, despite the fact that I set it in .env PHP_VERSION=8.0, phpinfo() on the site also gave out 7.4

Then I did

docker-compose build php-fpm

it and it solved the issue: on the site phpinfo() began to show PHP Version 8.0.15

And when I started changing php-cli and launched

docker-compose build workspace

it refused to build, at step 14 it gave out a sheet of warnings three screens down, and ended it like this:

ERROR: Service 'workspace' failed to build: The command '/bin/sh -c set -xe;     apt-get update -yqq &&     pecl channel-update pecl.php.net &&     groupadd -g ${PGID} laradock &&     useradd -l -u ${PUID} -g laradock -m laradock -G docker_env &&     usermod -p "*" laradock -s /bin/bash &&     apt-get install -yqq       apt-utils       libzip-dev zip unzip       php${LARADOCK_PHP_VERSION}-zip       nasm &&       php -m | grep -q 'zip'' returned a non-zero code: 1


I tried: to

docker-compose build --no-cache workspace

no purpose, the same thing, it comes to step 14, and it starts ...

6208fa8c66cff729933721.png

what should I do?

I don’t really understand docker, if you have something to advise, please write in the form of console commands.

Thank you.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexander Karabanov, 2022-02-13
@romicohen

Docker, in general, has nothing to do with it, the error occurs in one of the commands regarding updating and installing packages.
Try changing the Dockerfile as recommended in Support php 8.0.0

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question