Tag: php

Connecting from php to mysql in Docker

I am starting with docker and have some problems to make the right config. The Framework need a script to make the backend working. This needs a sql connection. I found a way to make phpmyadmin working, but the script can’t connect the mysql database. If someone with more Docker comprehension can give me a […]

docker php mongodb passing links to mongodb connection

I am trying to connect to mongodb from PHP 7. I have nginx container, php-fpm container and mongodb container. I installed mongodb driver using pecl and it is showing up in phpinfo(), mongodb ver. 1.2.3. Additionally I installed mongodb/mongodb using composer. I linked my containers to mongodb (eg –link mongodb_container:mongodb) Now when i am trying […]

Docker image container – where can I store my files?

I have created a docker image container which is running on a virtual machine (with docker toolbox). My Problem is now that I don’t know in which windows path I can store my files for the development? Also I’m not sure how I can open this image container in the browser (docker-machine ip)?

Serve dockerized ZendFramework2 Application with nginx

I want to Dockerize a ZendFramework2 Application with Nginx, Mysql, and PHP7. When I run docker-compose up all containers are built. But When I want to access localhost:8080 I get the nginx default page although the default.conf was replaced by my site.conf. A restart of the nginx container hasn’t changed anything. Because this is my […]

Access denied when running phinx command on Docker container

I am running the official MySQL Docker container for my PHP app. I am using Phinx for migrations. The MySQL image seems to work fine as I can connect to it as ‘dbuser’ (non-root) using MySQL Workbench. I can also connect with Docker exec as well. Problem occurs when I try to run any Phinx […]

Docker ERROR: for app Container command 'docker-php-entrypoint' not found or does not exist

When creating my own docker image it fails to start. The command line says: root@diskstation:docker-test2# docker-compose up -d Creating dockertest2_database_1 Creating dockertest2_app_1 ERROR: for app Container command ‘docker-php-entrypoint’ not found or does not exist. root@diskstation:docker-test2# The app script uses the “FROM php:7.0-apache” repository and doesn’t contain any specials things. Any clue what might be wrong […]

Install PHP 5.5.30 via DockerFile instead of PHP 5.5.9

I have an issue where my PHP version is affecting a project I’m trying to run inside of a docker container. When I run php -v in the container I get this. PHP 5.5.9-1ubuntu4.20 (cli) (built: Oct 3 2016 13:00:37) Copyright (c) 1997-2014 The PHP Group Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies with […]

Gitlab CI : Deploy php codes into docker image as production

I have setup gitlab ci as continues integration system, i want to test my application and then deploy app to a specific containers as production service.i want to use my own server and i don’t want to use AWS or other same services. 1 – Application should run test staging 2 – after success unit […]

Logging PHP API Request Info from Docker container

I’m working on a project where I have an iOs app connecting to a PHP API. I want to log all incoming requests to the website service for development purposes (ie I need a solution that can turn off and based on an environment variable). The API is run in a docker container, which is […]

docker-compose down default_network error

I have a docker-compose with some php, mysql and so on starting. After a few days, I cannot bring them down as everything stopps instead of mysql. It always gives me the following error: ERROR: network docker_default has active endpoints this is my docker-compose.yml version: ‘2’ services: php: build: php-docker/. container_name: php ports: – “9000:9000” […]

Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.