caparol6991

Untitled

Apr 9th, 2019
141
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Instalacja PHP:
  2.  
  3. sudo apt-get install apache2
  4. sudo apt-get install php libapache2-mod-php
  5. sudo nano /var/www/html/info.php
  6.  
  7. Wpisac:
  8.  
  9. <?php
  10. phpinfo();
  11. ?>
  12.  
  13. Potem:
  14.  
  15. sudo systemctl restart apache2
  16.  
  17. Nastepnie w przegladarce:
  18.  
  19. localhost/info.php
  20.  
  21. I powinno wyswietlic info o php jak wszystko pójdzie OK
  22.  
  23. Instalacja MongoDB
  24.  
  25. sudo apt install -y mongodb
  26. sudo systemctl status mongodb
  27.  
  28. sudo apt-get install php7.0-dev
  29. sudo pecl install mongodb
  30. sudo nano /etc/php/7.2/mods-available/mongodb.ini
  31. wpisac:
  32. extension=mongodb.so
  33.  
  34. sudo ln -sv /etc/php/7.2/mods-available/mongodb.ini /etc/php/7.2/apache2/conf.d/20-mongodb.ini
  35. sudo ln -sv /etc/php/7.2/mods-available/mongodb.ini /etc/php/7.2/cli/conf.d/20-mongodb.ini
  36. sudo service apache2 restart
  37.  
  38. Instalacja compass(do przegladania dokumentów mongo)
  39.  
  40. wget https://downloads.mongodb.com/compass/mongodb-compass_1.14.1_amd64.deb
  41. sudo dpkg -i mongodb-compass_1.14.1_amd64.deb
  42. apt --fix-broken install
  43. sudo dpkg -i mongodb-compass_1.14.1_amd64.deb
  44.  
  45. Instalacja composer
  46.  
  47. sudo apt-get install curl php-cli php-mbstring git unzip
  48. cd ~
  49. curl -sS https://getcomposer.org/installer -o composer-setup.php
  50. sudo php composer-setup.php --install-dir=/usr/local/bin --filename=composer
  51. composer
  52.  
  53. sudo chown -R $USER:$USER $HOME/.composer
  54.  
  55. composer require "mongodb/mongodb=^1.0.0" --ignore-platform-reqs
  56.  
  57. Pobranie projektu z gita
  58.  
  59. cd /var/www/html/
  60.  
  61. git clone <url>
RAW Paste Data