Questions tagged composer-php

Explore the latest questions and answers asked by our top developers.

php7.2-openssl Alpine Docker install error

I’m building a Docker image with Alpine, php7.2-fpm and Composer. The problem happens while trying to install Composer, which uses https to download the installer via php. I added the repository to be able to install php7.2 (which is used to install composer) and its packages: RUN wget -O /etc/apk/keys/phpearth.rsa.pub https://repos.php.earth/alpine/phpearth.rsa.pub && echo "https://repos.php.earth/alpine/v3.7" >> […]

By Kevin Souza
Published
Categorised as alpine, composer-php, docker, php, php-openssl Tagged , , , ,

Problems with repositories dev-master when using composer inside docker PHP container

I have a Docker Container installed with PHP 7.4 and Composer 1.10.1 but whenever I my application has a composer.json with a repository in versions "dev-master" it expects an key to the repository as tho it was private, but they’re all public. Example of one of the repositories in composer.json: … "require": { "kkamkou/tp-minify": "dev-master", […]

By David Alves
Published
Categorised as composer-php, docker, php Tagged , ,

Docker build Host Key Verification failed

I am getting Host key verification failed error on this docker file. SSH credentials are working fine as RUN git clone [email protected]:XXXX/YYY-XXX-YYY-XXX.git step is working fine but when RUN –mount=type=ssh,id=id_rsa RUN php -d memory_limit=2G $(which composer) install –no-progress –no-dev I am getting host key verification failed error. FROM base as build RUN curl https://files.magerun.net/n98-magerun2.phar -o […]

By user11931805
Published
Categorised as composer-php, docker, github, ssh-keys Tagged , , ,

How to manage a custom composre package in Gitlab: ci, development environment and deploy

I ran into a small issue when developing a Symfony application hosted in Gitlab and using pipelines. I want to add a custom bundle hosted in the same copmanys repo and I ran into some problems: We use docker-compose for development. We have a php container from where we run composer install/update/etc. So if I […]

By petekaner
Published
Categorised as composer-php, docker, gitlab Tagged , ,

Composer.lock bug with multiple psr-4 autoload – Your lock file cannot be installed on this system without changes

I have a Docker build working with following: Dockerfile # https://docs.docker.com/engine/reference/builder/#understand-how-arg-and-from-interact ARG PHP_VERSION=7.4.12 ARG OPENRESTY_VERSION=1.17.8.2 #ARG VARNISH_VERSION=6.5 ### ### 1. "php" stage ### FROM php:${PHP_VERSION}-fpm-alpine AS php # persistent / runtime deps RUN apk add –no-cache acl fcgi file gettext git rabbitmq-c-dev openssh-client supervisor ; ARG APCU_VERSION=5.1.19 ARG PECL_AMQP_VERSION=1.10.2 ARG PECL_REDIS_VERSION=5.3.2 RUN set -eux; apk […]

By BastienSander
Published
Categorised as composer-php, docker, php, symfony Tagged , , ,

laravel port 80 builder was not found

I’m trying to run laravel on port 80 using sudo php artisan serve –port=80 However, I’m shown with this issue The requested resource /builder/ was not found on this server ❌ It works on port 8000 Here’s my directory maybe i should move builder into the root diretory? ✅Issue Resolved Chrome was redirecting to http://localhost/builder […]

By youllbehaunted
Published
Categorised as composer-php, docker, laravel, nginx, php Tagged , , , ,

Single PHP Composer vendor directory for multiple projects

I am creating 100s of micro-services with Docker, each of which uses the same dependencies. I currently have a vendors directory for each project. Each project is responsible for managing the dependencies via composer update etc. Each project could have different versions of the dependencies but, in practice, they never will. This might be fine […]

By Mr Goobri
Published
Categorised as composer-php, docker, php Tagged , ,

file_put_contents(/root/.composer/cache/repo/https—flex.symfony.com/): failed to open stream: Is a directory error

I build my symfony 4 application with composer install inside docker container. Composer version 1.10.19 But i got this error. [ErrorException] file_put_contents(/root/.composer/cache/repo/https—flex.symfony.com/): failed to open stream: Is a directory If i run composer install 1 more time without any interruption build is succeeded. If i delete vendor and var/cache directory on project directory error accoured […]

By rmznbyk 1
Published
Categorised as composer-php, docker, symfony Tagged , ,

How to solve ‘Class ‘SymfonyComponentHttpFoundationRequest’ not found’ error on Laravel 6?

I have got a dockerized Laravel API project and suddenly I get the below error when running composer install or update commands. Composer install, update command run error Also when I try to access the APIs or run PHP cache clear commands Laravel app throws the below error. Error when accessing APIs or trying PHP […]

By Nasma Najeeb
Published
Categorised as composer-php, docker, laravel-6 Tagged , ,

Symfony autowiring issues since docker update

I’m having autowiring issues within symfony since I have updated my Docker to the latest version. I am not entirely sure of the causality here but certainly, my issues started appearing only after updating my docker. Since this was the case I obviously tried to revert back to a previous docker version but still had […]

By Jan Dries
Published
Categorised as composer-php, docker, php, symfony, wsl-2 Tagged , , , ,
1 2 3 4 5 12

Still Have Questions?


Our dedicated development team is here for you!

We can help you find answers to your question for as low as 5$.

Contact Us
faq