Docker quickly builds a PHP, Nginx, MySQL, Redis, Xdebug, Memcached development environment and evolves

Docker quickly builds a PHP, Nginx, MySQL, Redis, Xdebug, Memcached development environment and evolves

Pain points When the author tries to start a new web project, he often falls into the tedious task of re-establishing a Docker environment. I think that when you start a new project, or quickly in order to completely isolate it from previous projects, you will also set up a new docker environment. What you will get from this article Use docker-compose container orchestration technology to start all services in one step. On the official basis, the php container also packs some commonly used extensions (with build source code, you can package it yourself if you have strong hands-on skills), php, nginx, and mysql all come with custom configuration files (easy to configure and adjust for development and testing), all for download . Structure The environment built by this article is shown in the picture above. Environment description Operating environment Mac OS 10.13.6 Virtual Box 5.2.14 Ubuntu 16.04.4 Docker 17.07.0-ce Container Nginx 1.12.1-alpine PHP-fpm 5.6 MySQL 5.7 Redis 3.2 Memcached 1.4.27 Here to explain the author’s operating environment. I installed the vbox virtual machine on the Mac machine, installed the Docker environment in the debian environment inside the virtual machine, and placed the files in the Mac environment. Through the…

Note: MAC uses brew to configure nginx, php, mysql, phpfpm, redis

I used the built-in apache and php configuration on the mac before,it was all patchwork made by Baidu,no record. This time I changed it to nginx environment & # xff0c; write a note to record it & # xff0c; for later viewing & # xff0c; also hope to borrow flowers & offer Buddha & # xff0c; to help others. The content is all pieced together from the Internet,Thank you to all the selfless and dedicated gods on the Internet. Install xcode-select When installing some applications through brew, you need to use this program to compile ( If the words are not accurate, please forgive me&#xff09 ;,So in order to avoid installation failure,It is recommended to install first; xcode-select –install install homebrew /usr/bin/ruby -e “$(curl -fsSL https://raw.githubusercontent. com/Homebrew/install/master/install)” [ The system will , add a series of files in the /usl/local/* directory] The above information sources : Install nginx and The configuration command is as follows brew install nginx Test modification is successful sudo nginx -t Start sudo nginx Restart sudo nginx -s reload After installing nginx, run nginx -s reload directly, the following error will occur& #xff1a; The reason for this error is , there is no nginx.pid file ;…

Redis, MemCached, MongoDB comparison

Recently, I have been researching server performance optimization and high concurrent request access, investigating unstructured data (NoSQL) and memory acceleration (Cache), re-architecting and designing old platform services, and striving to save costs of $10,000 per month. Research projects mainly include Redis, MemCached, MongoDB, and Amazon’s DynamoDB Redis is an open source ANSI It is written in C language, supports network, can be memory-based or persistent log type, Key-Value database, and provides APIs in multiple languages. The development work is currently hosted by VMware. 1) Data model As a Key-value database, Redis also provides a mapping relationship between keys (Key) and values ​​(Value). In addition to regular values ​​or strings, Redis key values ​​can also be in one of the following forms: Lists Sets Sorted sets (ordered collection) Hashes (hash table) The data type of a key value determines the operations supported by the key value. Redis supports advanced atomic operations such as intersection, union, and difference of lists, sets, or ordered sets; at the same time, if the type of the key value is an ordinary number, Redis provides atomic operations such as self-increment. 2) Persistence: Redis usually stores data in memory, or is configured to use virtual memory. Data…

Contact Us

Contact us

181-3619-1160

Online consultation: QQ交谈

E-mail: 34331943@QQ.com

Working hours: Monday to Friday, 9:00-17:30, holidays off

Follow wechat
Scan wechat and follow us

Scan wechat and follow us

Follow Weibo
Back to top
首页
微信
电话
搜索