Dockfile for PHP and NodeJS && python 环境

这里不单独阐述什么是Docker和Dockerfile的作用。直接上代码,该Dockerfile用于 php 和 node 和python基本环境,主要是个人使用和这个blog背后的host。

FROM php:7.2-fpm
MAINTAINER lokie.wang@5imakeup.com
COPY sources.list /etc/apt/sources.list
RUN apt-get update && apt-get install -y vim
RUN apt-get install -y \
    libfreetype6-dev \
    libjpeg62-turbo-dev \
    libmcrypt-dev \
    libpng-dev \
    libssl-dev \
    zip \
&& docker-php-ext-install -j$(nproc) iconv mysqli \
&& docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ \
&& docker-php-ext-install -j$(nproc) gd \
&& docker-php-ext-install pdo_mysql \
&& docker-php-ext-install tokenizer \
&& docker-php-ext-install mbstring  \
&& docker-php-ext-install zip
RUN apt-get install -y libmemcached-dev && pecl install memcached && docker-php-ext-enable memcached
RUN pecl install redis && docker-php-ext-enable redis

RUN pecl install yaf && docker-php-ext-enable yaf
RUN curl -sS https://getcomposer.org/installer | php  && mv composer.phar /usr/local/bin/composer && /usr/local/bin/composer config -g repo.packagist composer https://packagist.laravel-china.org
RUN mkdir /workspce
RUN mkdir /deployment
WORKDIR /deployment
RUN apt-get install -y python
RUN apt-get install -y wget gnupg
RUN curl -sL https://deb.nodesource.com/setup_10.x | bash -
RUN apt-get install -y nodejs

Lokie博客
请先登录后发表评论
  • 最新评论
  • 总共0条评论
  • 本博客使用免费开源的 laravel-bjyblog v5.5.1.1 搭建 © 2014-2018 lokie.wang 版权所有 ICP证:沪ICP备18016993号
  • 联系邮箱:kitche1985@hotmail.com