0

I'm using docker to run my website. I built php-fpm container for php using.

Phpinfo shows this info in the browser:

Additional .ini files parsed    
/usr/local/etc/php/conf.d/docker-php-ext-gd.ini, 
/usr/local/etc/php/conf.d/docker-php-ext-mcrypt.ini, 
/usr/local/etc/php/conf.d/docker-php-ext-mongodb.ini, 
/usr/local/etc/php/conf.d/docker-php-ext-mysqli.ini, 
/usr/local/etc/php/conf.d/docker-php-ext-pdo_mysql.ini, 
/usr/local/etc/php/conf.d/docker-php-ext-soap.ini, 
/usr/local/etc/php/conf.d/docker-php-ext-zip.ini, 
/usr/local/etc/php/conf.d/ext-xdebug.ini

enter image description here

But at the same time class_exists('MongoClient') returns false

My docker-compose.yml (that is not all services):

installer:
  image: andreaskoch/dockerized-magento-installer
  environment:
    DOMAIN: dockerized-magento.local
  volumes_from:
    - nginx
  volumes:
    - ./config/installer/bin/install.sh:/bin/install.sh
  links:
    - "cache:rediscache"
    - "sessions:redissession"
    - "fullpagecache:redisfullpagecache"
    - "solr:solr"
    - "mysql:mysql"
    - "mongodb:mongodb"
  entrypoint: /bin/install.sh
nginx:
  image: nginx:latest
  ports:
    - "80:80"
    - "443:443"
  links:
    - "php"
  volumes:
    - ./logs/nginx:/var/log/nginx
  volumes_from:
    - php
php:
  image: avestique/php7_fpm
  links:
    - "cache:rediscache"
    - "sessions:redissession"
    - "fullpagecache:redisfullpagecache"
    - "solr:solr"
    - "mysql:mysql"
    - "mongodb:mongodb"
  volumes:
    - ./config/installer/php/php.ini:/usr/local/etc/php/php.ini
    - ./config/installer/php/ext-xdebug.ini:/usr/local/etc/php/conf.d/ext-xdebug.ini
    - ./htdocs:/var/www/htdocs
mongodb:
  image: mongo:latest
  environment:
    - MONGO_DATA_DIR=/data/db
    - MONGO_LOG_DIR=/dev/null
  volumes:
    - ./data/mongo:/data/db
  ports:
      - 27017:27017
  command: mongod --smallfiles --logpath=/dev/null

Actually andreaskoch/dockerized-magento-installer has php5.6. But again - phpinfo shows PHP Version 7.0.28 and Server API FPM/FastCGI and it looks to avestique/php7_fpm image.

Why MongoClient is not shown then?

Anthony
  • 3,218
  • 3
  • 43
  • 73

0 Answers0