We were playing with Kubernetes last week, however the project was just a small PHP file with phpinfo() function call, no big deal.
Today my colle...
For further actions, you may consider blocking this person and/or reporting abuse
Great writeup! This is going to help me out a ton.
After reading through the article and looking at your example repo, I think the directory structure at the top of this article would look more like this (i.e. dedicated
docker
andsrc
directories):For those which rather want to use postgresql instead of mariadb.
And I had to add
RUN apk add --no-cache bash
in php-fpm dockerfile (due to this warning: env: can't execute 'bash': No such file or directory).
Greatly explained setup, thanks! How to downgrade php to 7.4? I tried replacing the first line in
docker/php-fpm/Dockerfile
toFROM php:7.4-fpm-alpine
and fired up my container but didn't work.docker exec -it docker_php-fpm_1 php -v
outputsPHP 8.0.9 (cli)
. Any thoughts?Hi, great post!
this is where i get an error:
when i try docker-compose up, i get this error
Error starting userland proxy: listen tcp 0.0.0.0:80: bind: address already in use
What am I doing wrong?
Any help appreciated
Hello,
thank you for this amazing post,
i have an issue with login, once i submit to login i got this error :
php-fpm_1 | [21-Sep-2020 16:45:16] WARNING: [pool www] child 38 exited on signal 9 (SIGKILL) after 318.447129 seconds from start
php-fpm_1 | [21-Sep-2020 16:45:16] NOTICE: [pool www] child 50 started
any idea ?
2020/09/21 16:48:50 [error] 29#29: *37 recv() failed (104: Connection reset by peer) while reading response header from upstream, client: 192.168.0.1, server: localhost, request: "POST /login HTTP/1.1", upstream: "fastcgi://192.168.0.3:9000", host: "localhost:1609", referrer: "localhost:1609/login"
Hello nice Tutorial.
I gott a Error while Docker-compose
=> ERROR [stage-0 2/7] COPY wait-for-it.sh /usr/bin/wait-for-it 0.0s
can someone help me to solve that problem?
Please have a look at the Gitlab Repo mentioned in the article. There you will find the wait-for-it.sh. You have to add it to your code. It's not included in the article.
UPDATE 31.07.2021
if someone having the problem with error from apline:
/bin/sh: Operation not permitted
or
*some_command* returned a non-zero code: 2
just change first line in docker/php-fpm/Dockerfile to:
FROM php:8.0-fpm-alpine3.13
They mess something in update 3.14, changing to older version fixes that
Hi there!
I am a beginner developer. I downloaded your project from your repo for learning purposes.
I use Maker Bundle to automatically create an user.
When I run the command (docker and mysql are already running):
php bin/console make:migration
this error is shown several times in a row:
SQLSTATE[HY000] [2002] php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution
Could be possible that this bundle is unable to know where my database is running? How could I solve this issue?
Any help would be welcome. Thanks for your excellent article and cheers.
You should connect to you docker terminal to run the above command... It should be something like
docker exec -it docker_container_name ash
. Your docker_container_name should be listed indocker ps -a
Excellent article !
Thanks! Glad you liked it!
Great article!
Would be great if I was able to enter container bash by running
Is it possible to update Dockerfile to enable that?
You can try
docker exec -it nginx sh
If you prefer apache over nginx and you need phpmyadmin, mysql, email dockerized services, I would recommend checking this repository - github.com/kasteckis/symfony-docke...
Great tutorial !
Just one thing, remember to add "wait-for-it.sh" in "php-fpm" directory ;)
Thk's a lot for this article, simple and functional. +1
Wonderful post! I was wondering how one would deploy something like this on AWS/Azure?