diff --git a/logstash/README.md b/logstash/README.md index dba6ebe..73b97ef 100644 --- a/logstash/README.md +++ b/logstash/README.md @@ -7,5 +7,6 @@ * 默认163镜像源。 * 中国时区。 * 中文语言包 +* 安装logstash插件: gelf diff --git a/nginx-pureftpd/docker-compose.yml b/nginx-pureftpd/docker-compose.yml index b0596b4..a732c2c 100644 --- a/nginx-pureftpd/docker-compose.yml +++ b/nginx-pureftpd/docker-compose.yml @@ -1,20 +1,20 @@ version: '2' services: web: - build: nginx - container_name: "gitbook-web" + image: registry.cn-hangzhou.aliyuncs.com/kennylee/nginx:alpine-1.11.9 + container_name: "nginx" ports: - - "3022:80" - volumes: + - "80:80" + volumes: - ./data/html/:/usr/share/nginx/html - environment: - - TZ=Asia/Shanghai + - ./nginx/conf/nginx.conf:/etc/nginx/nginx.conf + - ./nginx/conf/conf.d/:/etc/nginx/conf.d/ restart: always ftp: build: ftp container_name: "gitbook-ftp" ports: - - "3021:21" + - "21:21" - "30000-30009:30000-30009" volumes: - ./data/html/:/usr/share/nginx/html diff --git a/nginx-pureftpd/nginx/Dockerfile b/nginx-pureftpd/nginx/Dockerfile deleted file mode 100755 index cbbe5f7..0000000 --- a/nginx-pureftpd/nginx/Dockerfile +++ /dev/null @@ -1,43 +0,0 @@ -# Http Proxy -# -# see also https://github.com/nginxinc/docker-nginx -# Authoer: kennylee26 -# NAME: kennylee26/httpproxy -# Command format: Instruction [arguments command] .. - -# 第一行必须指定基于的基础镜像 -FROM registry.alauda.cn/kenny/docker-nginx - -# 维护者信息 -MAINTAINER kennylee26 - -ENV EGINX_HOME=/etc/nginx - -RUN echo "deb http://mirrors.163.com/debian/ jessie main non-free contrib\n\ - deb http://mirrors.163.com/debian/ jessie-updates main non-free contrib\n\ - deb http://mirrors.163.com/debian/ jessie-backports main non-free contrib\n\ - deb-src http://mirrors.163.com/debian/ jessie main non-free contrib\n\ - deb-src http://mirrors.163.com/debian/ jessie-updates main non-free contrib\n\ - deb-src http://mirrors.163.com/debian/ jessie-backports main non-free contrib\n\ - deb http://mirrors.163.com/debian-security/ jessie/updates main non-free contrib\n\ - deb-src http://mirrors.163.com/debian-security/ jessie/updates main non-free contrib\n\ - deb http://ftp.cn.debian.org/debian jessie main" > /etc/apt/sources.list - -RUN apt-get -y update -# recommend -RUN apt-get install -y \ - curl vim wget - -# clean -RUN apt-get clean && \ - rm -rf /var/lib/apt/lists/* - -VOLUME ["/var/cache/nginx"] -# web resource -VOLUME /usr/share/nginx/html - -ADD default.conf $EGINX_HOME/conf.d/ - -EXPOSE 80 443 - -CMD ["nginx", "-g", "daemon off;"] diff --git a/nginx-pureftpd/nginx/default.conf b/nginx-pureftpd/nginx/config/conf.d/default.conf similarity index 100% rename from nginx-pureftpd/nginx/default.conf rename to nginx-pureftpd/nginx/config/conf.d/default.conf diff --git a/nginx-pureftpd/nginx/config/nginx.conf b/nginx-pureftpd/nginx/config/nginx.conf new file mode 100644 index 0000000..8f66c5c --- /dev/null +++ b/nginx-pureftpd/nginx/config/nginx.conf @@ -0,0 +1,31 @@ +user nginx; +worker_processes 1; + +error_log /var/log/nginx/error.log warn; +pid /var/run/nginx.pid; + + +events { + worker_connections 1024; +} + + +http { + include /etc/nginx/mime.types; + default_type application/octet-stream; + + log_format main '$remote_addr - $remote_user [$time_local] "$request" ' + '$status $body_bytes_sent "$http_referer" ' + '"$http_user_agent" "$http_x_forwarded_for"'; + + access_log /var/log/nginx/access.log main; + + sendfile on; + #tcp_nopush on; + + keepalive_timeout 65; + + #gzip on; + + include /etc/nginx/conf.d/*.conf; +} diff --git a/supervisord/Dockerfile b/supervisord/Dockerfile new file mode 100755 index 0000000..b3433b1 --- /dev/null +++ b/supervisord/Dockerfile @@ -0,0 +1,19 @@ +# Ubuntu +# +# Base Docker Image http://dockerfile.github.io/#/ubuntu +# Authoer: kennylee26 + +FROM registry.cn-hangzhou.aliyuncs.com/kennylee/ubuntu + +MAINTAINER kennylee26 + +# Install. +RUN \ + apt-get update && \ + apt-get install -y inetutils-ping net-tools dnsutils supervisor && \ + rm -rf /var/lib/apt/lists/* + +COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf + +# Define default command. +CMD ["/usr/bin/supervisord"] diff --git a/supervisord/supervisord.conf b/supervisord/supervisord.conf new file mode 100644 index 0000000..3fb016d --- /dev/null +++ b/supervisord/supervisord.conf @@ -0,0 +1,3 @@ +[supervisord] +nodaemon=true +