mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-07-02 14:25:38 +08:00
update Dockerfile to fit mysqlnd
This commit is contained in:
19
Dockerfile
19
Dockerfile
@@ -1,10 +1,25 @@
|
||||
FROM phpswoole/swoole:4.4.15-php7.3
|
||||
FROM ubuntu:18.04
|
||||
WORKDIR /app/
|
||||
RUN echo "Asia/Shanghai" > /etc/timezone
|
||||
#RUN dpkg-configure -f noninteractive tzdata
|
||||
ENV LANG C.UTF_8
|
||||
ENV LC_ALL C.UTF-8
|
||||
ENV LANGUAGE C.UTF-8
|
||||
|
||||
RUN apt-get update && apt-get install -y software-properties-common tzdata
|
||||
RUN dpkg-reconfigure -f noninteractive tzdata
|
||||
VOLUME ["/app/zhamao-framework/"]
|
||||
RUN add-apt-repository ppa:ondrej/php && \
|
||||
apt-get update && \
|
||||
apt-get install php php-dev php-mbstring gcc make openssl \
|
||||
php-mbstring php-json php-curl php-mysql -y && \
|
||||
apt-get install wget composer -y && \
|
||||
wget https://github.com/swoole/swoole-src/archive/v4.5.0.tar.gz && \
|
||||
tar -zxvf v4.5.0.tar.gz && \
|
||||
cd swoole-src-4.5.0/ && \
|
||||
phpize && ./configure --enable-openssl --enable-mysqlnd && make -j2 && make install && \
|
||||
(echo "extension=swoole.so" >> $(php -i | grep "Loaded Configuration File" | awk '{print $5}'))
|
||||
|
||||
|
||||
ADD . /app/zhamao-framework
|
||||
ADD . /app/zhamao-framework-bak
|
||||
#RUN cd /app/zhamao-framework && composer update && composer clearcache
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
FROM richardchien/cqhttp:latest
|
||||
RUN apt-get update && apt-get install -y software-properties-common && \
|
||||
add-apt-repository ppa:ondrej/php && \
|
||||
RUN apt-get update && apt-get install -y software-properties-common tzdata
|
||||
RUN dpkg-reconfigure -f noninteractive tzdata
|
||||
RUN add-apt-repository ppa:ondrej/php && \
|
||||
apt-get update && \
|
||||
apt-get install php7.3 php7.3-dev php7.3-mbstring gcc make openssl \
|
||||
php7.3-mbstring php7.3-json php7.3-ctype php7.3-curl -y && \
|
||||
apt-get install php php-dev php-mbstring gcc make openssl \
|
||||
php-mbstring php-json php-curl php-mysql -y && \
|
||||
apt-get install wget composer -y && \
|
||||
wget https://github.com/swoole/swoole-src/archive/v4.5.0.tar.gz && \
|
||||
tar -zxvf v4.5.0.tar.gz && \
|
||||
cd swoole-src-4.5.0/ && \
|
||||
phpize7.3 && ./configure --enable-openssl && make -j2 && make install && \
|
||||
phpize && ./configure --enable-openssl --enable-mysqlnd && make -j2 && make install && \
|
||||
(echo "extension=swoole.so" >> $(php -i | grep "Loaded Configuration File" | awk '{print $5}'))
|
||||
ADD start.sh /home/user/start.sh
|
||||
RUN chown user:user /home/user/start.sh && chmod +x /home/user/start.sh
|
||||
|
||||
Reference in New Issue
Block a user