MongoDB

From DreamFactory
Jump to: navigation, search
 
Line 4: Line 4:
  
 
# Make sure you have all the required packages
 
# Make sure you have all the required packages
#* <source lang="bash">$ sudo apt-get install php-dev php-pear build-essential libsslcommon2-dev libssl-dev libcurl4-openssl-dev pkg-config</source>
+
#* <source lang="bash">$ sudo apt-get install php7.1-dev php-pear build-essential libsslcommon2-dev libssl-dev libcurl4-openssl-dev pkg-config</source>
 
# Install from PECL
 
# Install from PECL
 
#* <source lang="bash">$ sudo pecl install mongodb</source>
 
#* <source lang="bash">$ sudo pecl install mongodb</source>
 
# Create the ini file
 
# Create the ini file
#* <source lang="bash">$ sudo sh -c 'echo "extension=mongodb.so" > /etc/php/7.0/mods-available/mongodb.ini'</source>
+
#* <source lang="bash">$ sudo sh -c 'echo "extension=mongodb.so" > /etc/php/7.1/mods-available/mongodb.ini'</source>
 
# Enable the extension
 
# Enable the extension
 
#* <source lang="bash">$ sudo phpenmod mongodb</source>
 
#* <source lang="bash">$ sudo phpenmod mongodb</source>
 
# Restart your webserver app and/or php-fpm
 
# Restart your webserver app and/or php-fpm

Latest revision as of 19:58, 13 September 2017

This module should already be installed if you have successfully installed DreamFactory. It allows you to use MongoDB databases.

  • The version of php-mongodb in the APT repositories is no longer high enough to satisfy the requirements of the mongodb repos used. Please install using PECL.
  1. Make sure you have all the required packages
    • $ sudo apt-get install php7.1-dev php-pear build-essential libsslcommon2-dev libssl-dev libcurl4-openssl-dev pkg-config
  2. Install from PECL
    • $ sudo pecl install mongodb
  3. Create the ini file
    • $ sudo sh -c 'echo "extension=mongodb.so" > /etc/php/7.1/mods-available/mongodb.ini'
  4. Enable the extension
    • $ sudo phpenmod mongodb
  5. Restart your webserver app and/or php-fpm