-
Notifications
You must be signed in to change notification settings - Fork 69
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #41 from fucongcong/dev
文档更新,v2.0预告
- Loading branch information
Showing
4 changed files
with
71 additions
and
103 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,54 +1,60 @@ | ||
FROM php:7.1-fpm | ||
FROM php:7.1-cli | ||
|
||
MAINTAINER fucongcong | ||
|
||
RUN apt-get update -yqq | ||
RUN apt-get install -yqq libpcre3-dev | ||
RUN apt-get install -yqq libfreetype6-dev | ||
RUN apt-get install -yqq libjpeg62-turbo-dev | ||
RUN apt-get install -yqq libmcrypt-dev | ||
RUN apt-get install -yqq libpng-dev | ||
RUN apt-get install -yqq libicu-dev | ||
RUN apt-get install -yqq git | ||
RUN apt-get install -yqq python | ||
RUN docker-php-ext-install gd | ||
RUN docker-php-ext-install zip | ||
RUN docker-php-ext-install intl | ||
RUN apt-get install -yqq build-essential chrpath git-core libssl-dev libfontconfig1-dev libxft-dev | ||
RUN apt-get install -yqq wget | ||
RUN apt-get install -yqq zip | ||
RUN wget https://github.com/redis/hiredis/archive/v0.13.3.zip \ | ||
RUN apt-get update -yqq \ | ||
&& apt-get install -yqq wget \ | ||
&& apt-get install -yqq libpng-dev \ | ||
&& apt-get install -yqq libicu-dev \ | ||
&& apt-get install -yqq libmcrypt-dev \ | ||
&& apt-get install -yqq libpcre3-dev \ | ||
&& apt-get install -yqq libjpeg62-turbo-dev \ | ||
&& apt-get install -yqq libfreetype6-dev \ | ||
&& apt-get install -yqq build-essential chrpath libssl-dev libfontconfig1-dev libxft-dev \ | ||
&& apt-get install -yqq zip \ | ||
&& wget https://github.com/redis/hiredis/archive/v0.13.3.zip \ | ||
&& unzip v0.13.3.zip \ | ||
&& rm v0.13.3.zip \ | ||
&& cd hiredis-0.13.3 \ | ||
&& make && make install \ | ||
&& ldconfig \ | ||
&& cd .. \ | ||
&& rm -rf hiredis-0.13.3 | ||
RUN wget https://github.com/swoole/swoole-src/archive/v1.9.22.zip \ | ||
&& unzip v1.9.22.zip \ | ||
&& cd swoole-src-1.9.22 \ | ||
&& rm -rf hiredis-0.13.3 \ | ||
&& wget https://github.com/swoole/swoole-src/archive/v1.10.1.zip \ | ||
&& unzip v1.10.1.zip \ | ||
&& rm v1.10.1.zip \ | ||
&& cd swoole-src-1.10.1 \ | ||
&& phpize \ | ||
&& ./configure --enable-async-redis \ | ||
&& make \ | ||
&& make install \ | ||
&& cd .. \ | ||
&& rm -rf swoole-src-1.9.22 | ||
RUN echo "extension=swoole.so" > /usr/local/etc/php/conf.d/docker-php-ext-swoole.ini | ||
RUN php -m | ||
|
||
RUN wget http://pecl.php.net/get/redis-4.1.0.tgz \ | ||
&& rm -rf swoole-src-1.10.1 \ | ||
&& echo "extension=swoole.so" > /usr/local/etc/php/conf.d/docker-php-ext-swoole.ini \ | ||
&& wget http://pecl.php.net/get/redis-4.1.0.tgz \ | ||
&& tar xzf redis-4.1.0.tgz \ | ||
&& rm redis-4.1.0.tgz \ | ||
&& cd redis-4.1.0 \ | ||
&& phpize \ | ||
&& ./configure \ | ||
&& make \ | ||
&& make install \ | ||
&& cd .. \ | ||
&& rm -rf redis-4.1.0 | ||
RUN echo "extension=redis.so" > /usr/local/etc/php/conf.d/docker-php-ext-redis.ini | ||
RUN php -m | ||
|
||
RUN docker-php-ext-install pdo_mysql | ||
RUN php -m | ||
&& rm -rf redis-4.1.0 \ | ||
&& echo "extension=redis.so" > /usr/local/etc/php/conf.d/docker-php-ext-redis.ini \ | ||
&& docker-php-ext-install gd \ | ||
&& docker-php-ext-install zip \ | ||
&& docker-php-ext-install intl \ | ||
&& docker-php-ext-install mcrypt \ | ||
&& docker-php-ext-install exif \ | ||
&& docker-php-ext-install gettext \ | ||
&& docker-php-ext-install pdo_mysql \ | ||
&& docker-php-ext-install sockets \ | ||
&& apt-get purge --auto-remove -y \ | ||
wget \ | ||
&& apt-get purge --auto-remove -y \ | ||
zip | ||
RUN apt-get clean \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
ADD . /GroupCo | ||
WORKDIR /GroupCo |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,49 +1,2 @@ | ||
#### 网关层 | ||
特点:最外层网关需要高性能、支持高并发。 | ||
|
||
- Go语言实现Gateway,方便定制 | ||
- Kong(nginx+lua基于nginx) | ||
- Traefik(Go实现的,性能不如nginx) | ||
|
||
#### 服务聚合层 | ||
特点:需要快速开发应对外部业务的多变,调用基础服务即可。io较密集,建议使用异步框架。 | ||
|
||
- GroupCo (php的异步协程框架,php的快速开发与异步协程的支持并发) | ||
|
||
#### 基础服务层 | ||
特点:基础服务要求稳定,严谨。使用RPC/Http与上层通信 | ||
|
||
- GroupCo(内置RPC,php开发快) | ||
- [GroupCo-java](https://github.com/fucongcong/GroupCo-java) (java实现的服务层,更严谨,低耦合) | ||
|
||
#### 日志分析 | ||
|
||
- ELK(开箱即用) | ||
|
||
#### 配置中心 | ||
|
||
- GroupCo内置[APOLLO](https://github.com/ctripcorp/apollo) | ||
|
||
#### 服务发现 | ||
|
||
- 基于Zookeeper | ||
- 基于Redis | ||
- 基于Mysql | ||
|
||
#### 分布式队列 | ||
|
||
- 基于Redis | ||
- Kafaka | ||
- Beanstalk | ||
- Rabbitmq | ||
- RocketMQ | ||
|
||
#### 分布式任务调度 | ||
|
||
#### 自动化部署发布 | ||
|
||
- CI | ||
- jenkins | ||
|
||
#### 流程图 | ||
![](/service.png) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters