mirror of
https://github.com/macintoshplus/php.git
synced 2026-03-24 17:02:12 +01:00
Compare commits
20 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9dc1179eb9 | ||
|
|
aabc24378e | ||
|
|
53165514dd | ||
|
|
2157bdefe0 | ||
|
|
f23ee67f4f | ||
|
|
2a750c3bfa | ||
|
|
0f3caf4e8e | ||
|
|
edc26bb1e7 | ||
|
|
f9a2fd9044 | ||
|
|
bae14a82e5 | ||
|
|
2816941770 | ||
|
|
94eb35f045 | ||
|
|
a51d1a2983 | ||
|
|
403fea55ca | ||
|
|
f578cfa282 | ||
|
|
190366c7cc | ||
|
|
dd9b5397a8 | ||
|
|
46ae771d8f | ||
|
|
f7f43ffd1a | ||
|
|
62886c0e20 |
55
Dockerfile
55
Dockerfile
@@ -2,44 +2,59 @@
|
||||
# Jb Nahan PHP 5.6 container
|
||||
##
|
||||
|
||||
FROM debian:jessie
|
||||
MAINTAINER Jean-Baptiste Nahan <jean-baptiste@nahan.fr>
|
||||
FROM debian:jessie
|
||||
MAINTAINER Jean-Baptiste Nahan <jean-baptiste@nahan.fr>
|
||||
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
RUN apt-get update && apt-get -y upgrade
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
RUN echo 'deb http://httpredir.debian.org/debian jessie-backports main' > /etc/apt/sources.list.d/jessie-backports.list
|
||||
RUN apt-get update && apt-get -y upgrade
|
||||
|
||||
# Common packages
|
||||
RUN apt-get -y install curl wget locales nano git subversion
|
||||
ENV CA_CERTIFICATES_JAVA_VERSION 20161107~bpo8+1
|
||||
|
||||
RUN echo "Europe/Paris" > /etc/timezone && dpkg-reconfigure -f noninteractive tzdata
|
||||
RUN export LANGUAGE=en_US.UTF-8 && \
|
||||
RUN apt-get -y install curl wget locales nano git subversion sudo php5-dev librabbitmq-dev openjdk-8-jre-headless ca-certificates-java="$CA_CERTIFICATES_JAVA_VERSION"
|
||||
|
||||
RUN echo "Europe/Paris" > /etc/timezone && dpkg-reconfigure -f noninteractive tzdata
|
||||
RUN export LANGUAGE=en_US.UTF-8 && \
|
||||
export LANG=en_US.UTF-8 && \
|
||||
export LC_ALL=en_US.UTF-8 && \
|
||||
locale-gen en_US.UTF-8 && \
|
||||
DEBIAN_FRONTEND=noninteractive dpkg-reconfigure locales
|
||||
|
||||
# Apache
|
||||
RUN apt-get -y install pdftk mysql-client xfonts-75dpi libfontconfig1 libjpeg62-turbo libxrender1 xfonts-base fontconfig
|
||||
RUN /var/lib/dpkg/info/ca-certificates-java.postinst configure
|
||||
RUN ln -s /usr/bin/java /bin/java
|
||||
|
||||
COPY bin/wkhtmltox-0.12.2.1_linux-jessie-amd64.deb /root/
|
||||
RUN dpkg -i /root/wkhtmltox-0.12.2.1_linux-jessie-amd64.deb
|
||||
|
||||
# Apache
|
||||
RUN apt-get -y install pdftk mysql-client xfonts-75dpi libfontconfig1 libjpeg62-turbo libxrender1 xfonts-base fontconfig
|
||||
|
||||
COPY bin/wkhtmltox-0.12.2.1_linux-jessie-amd64.deb /root/
|
||||
RUN dpkg -i /root/wkhtmltox-0.12.2.1_linux-jessie-amd64.deb
|
||||
|
||||
# PHP
|
||||
RUN apt-get -y install php5-cli php5-curl php-soap php5-imagick php5-gd php5-mcrypt php5-mysql php5-xmlrpc php5-xsl php5-xdebug php-apc php5-ldap php5-gmp php5-intl php5-redis
|
||||
RUN cp /usr/share/php5/php.ini-development /etc/php5/cli/php.ini
|
||||
RUN sed -i 's/\;date\.timezone\ \=/date\.timezone\ \=\ Europe\/Paris/g' /etc/php5/cli/php.ini
|
||||
RUN apt-get -y install php5-cli php5-curl php-soap php5-imagick php5-gd php5-mcrypt php5-mysql php5-xmlrpc php5-xsl php-apc php5-apcu php5-ldap php5-gmp php5-intl php5-redis php5-sqlite
|
||||
RUN cp /usr/share/php5/php.ini-development /etc/php5/cli/php.ini
|
||||
RUN sed -i 's/\;date\.timezone\ \=/date\.timezone\ \=\ Europe\/Paris/g' /etc/php5/cli/php.ini
|
||||
RUN sed -i 's/\memory_limit\ \=\ 128M/memory_limit\ \=\ -1/g' /etc/php5/cli/php.ini
|
||||
RUN sed -i 's/disable_functions\ \=\ pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,/\;disable_functions\ \=\ pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,/g' /etc/php5/cli/php.ini
|
||||
#RUN sed -i 's/;include_path = ".:\/usr\/share\/php"/include_path = ".:\/var\/www\/library"/g' /etc/php5/cli/php.ini
|
||||
#RUN sed -i 's/;include_path = ".:\/usr\/share\/php"/include_path = ".:\/var\/www\/library"/g' /etc/php5/cli/php.ini
|
||||
|
||||
|
||||
|
||||
#PEAR
|
||||
RUN pear update-channels && pear install pecl/amqp-1.9.1 && pear install pecl/xdebug-2.5.5
|
||||
RUN echo "extension=amqp.so" > /etc/php5/mods-available/amqp.ini
|
||||
RUN echo "zend_extension=xdebug.so" > /etc/php5/mods-available/xdebug.ini
|
||||
|
||||
RUN pear channel-discover pear.phpmd.org && pear channel-discover pear.pdepend.org && pear channel-discover pear.phpdoc.org && pear channel-discover components.ez.no
|
||||
RUN pear install PHP_CodeSniffer && pear install --alldeps phpmd/PHP_PMD
|
||||
RUN git clone https://github.com/lapistano/Symfony2-coding-standard.git /usr/share/php/PHP/CodeSniffer/Standards/Symfony2
|
||||
#RUN cd /etc/php5/apache2/conf.d && ln -s ../../mods-available/amqp.ini 20-amqp.ini
|
||||
#RUN cd /etc/php5/cli/conf.d && ln -s ../../mods-available/amqp.ini 20-amqp.ini
|
||||
RUN php5enmod amqp xdebug
|
||||
|
||||
RUN useradd -s /bin/bash --home /sources --no-create-home phpuser
|
||||
COPY bin/fixright /
|
||||
RUN chmod +x /fixright
|
||||
|
||||
VOLUME /src
|
||||
VOLUME /sources
|
||||
|
||||
WORKDIR /src
|
||||
WORKDIR /sources
|
||||
|
||||
|
||||
21
README.md
21
README.md
@@ -1,2 +1,23 @@
|
||||
# php56
|
||||
Docker Image With PHP56 and many tools !
|
||||
|
||||
Dev tools :
|
||||
|
||||
* GIT
|
||||
* SVN
|
||||
* Curl
|
||||
* Wget
|
||||
* Nano
|
||||
* openJdk
|
||||
|
||||
Executable tools :
|
||||
|
||||
* wkhtmltopdf
|
||||
* pdftk
|
||||
|
||||
Dev quality :
|
||||
|
||||
* PHP Mess Detector (phpmd)
|
||||
* PHP_CodeSniffer (with Symfony2 rules)
|
||||
|
||||
This image has already used for run website (with macintoshplus/apache2-php:php56), run RabbitMQ worker, run tests and make PHPCS and PHPMD repport.
|
||||
|
||||
12
bin/fixright
Executable file
12
bin/fixright
Executable file
@@ -0,0 +1,12 @@
|
||||
#!/bin/bash
|
||||
|
||||
if [ -d "/sources" ]
|
||||
then
|
||||
|
||||
USERID=$(stat -c "%u" /sources)
|
||||
GROUPID=$(stat -c "%g" /sources)
|
||||
|
||||
groupmod -g $GROUPID phpuser
|
||||
usermod -u $USERID -g $GROUPID phpuser
|
||||
|
||||
fi
|
||||
Reference in New Issue
Block a user