mirror of
https://github.com/vimagick/dockerfiles.git
synced 2025-01-20 04:59:25 +02:00
fix mysql
This commit is contained in:
parent
f1edd7ce6a
commit
8d2545242d
@ -10,8 +10,7 @@ RUN a2enmod rewrite
|
||||
RUN apt-get update && apt-get install -y libpng12-dev libjpeg-dev libpq-dev \
|
||||
&& rm -rf /var/lib/apt/lists/* \
|
||||
&& docker-php-ext-configure gd --with-png-dir=/usr --with-jpeg-dir=/usr \
|
||||
&& docker-php-ext-install gd mysqli mbstring \
|
||||
&& docker-php-ext-configure mysqli
|
||||
&& docker-php-ext-install gd mbstring mysql
|
||||
|
||||
WORKDIR /var/www/html
|
||||
|
||||
@ -24,9 +23,5 @@ RUN curl -fSL ${MANTIS_URL} -o ${MANTIS_FILE} \
|
||||
&& echo "${MANTIS_MD5} ${MANTIS_FILE}" | md5sum -c - \
|
||||
&& tar -xz --strip-components=1 -f ${MANTIS_FILE} \
|
||||
&& rm ${MANTIS_FILE} \
|
||||
&& sed -e "/g_hostname/s/'localhost'/'mysql'/" \
|
||||
-e "/g_db_username/s/'mantisdbuser'/'root'/" \
|
||||
-e "/g_db_password/s/''/'root'/" \
|
||||
config_inc.php.sample > config_inc.php \
|
||||
&& chown -R www-data:www-data .
|
||||
|
||||
|
@ -15,9 +15,20 @@ mantisbt:
|
||||
restart: always
|
||||
|
||||
db:
|
||||
image: mariadb
|
||||
image: mysql
|
||||
environment:
|
||||
- MYSQL_ROOT_PASSWORD=root
|
||||
- MYSQL_DATABASE=bugtracker
|
||||
restart: always
|
||||
```
|
||||
|
||||
## setup
|
||||
|
||||
```
|
||||
$ docker exec -it mantisbt_mantisbt_1 bash
|
||||
>>> echo 'date.timezone = "Asia/Shanghai"' > /usr/local/etc/php/php.ini
|
||||
>>> exit
|
||||
$ firefox http://localhost/admin/install.php
|
||||
>>> username: administrator
|
||||
>>> password: root
|
||||
```
|
||||
|
Loading…
x
Reference in New Issue
Block a user