Commit c9cd3734 authored by David Ivain's avatar David Ivain
Browse files

petit avancement

parent fbb27344
FROM php:5.6-apache-stretch FROM php:5.6-apache-jessie
RUN mkdir /persist RUN mkdir /persist
RUN apt-get update RUN apt-get update
# RUN apt-get upgrade # RUN apt-get upgrade
RUN apt-get install wget git -y RUN apt-get install wget git -y
RUN apt-get install -y nano bsdtar curl zip unzip RUN apt-get install -y nano bsdtar curl zip unzip
RUN docker-php-ext-install mysqli pdo pdo_mysql
RUN curl -sS https://getcomposer.org/installer | php RUN curl -sS https://getcomposer.org/installer | php
RUN mv composer.phar /usr/local/bin/composer RUN mv composer.phar /usr/local/bin/composer
...@@ -17,9 +18,9 @@ WORKDIR /var/www/html ...@@ -17,9 +18,9 @@ WORKDIR /var/www/html
RUN wget https://gitlab-fil.univ-lille.fr/mikael.salson/alecsia/-/archive/david/alecsia-david.zip RUN wget https://gitlab-fil.univ-lille.fr/mikael.salson/alecsia/-/archive/david/alecsia-david.zip
RUN unzip alecsia-david.zip RUN unzip alecsia-david.zip
RUN mv alecsia-david alecsia RUN mv alecsia-david alecsia
WORKDIR alecsia WORKDIR /var/www/html/alecsia
RUN ls docker/persist
RUN cp ./docker/config/parameters.yml ./app/config/parameters.yml RUN cp ./docker/config/parameters.yml ./app/config/parameters.yml
RUN mkdir upload RUN mkdir upload
RUN composer install RUN composer install
RUN php vendor/sensio/distribution-bundle/Sensio/Bundle/DistributionBundle/Resources/bin/build_bootstrap.php RUN php vendor/sensio/distribution-bundle/Sensio/Bundle/DistributionBundle/Resources/bin/build_bootstrap.php
RUN export LANG=en_US.UTF-8
parameters: parameters:
database_driver : pdo_mysql database_driver : pdo_mysql
database_host : localhost database_host : 172.19.0.3
database_port : ~ database_port : ~
database_name : alecsia_legacy database_name : alecsia_legacy
database_user : root database_user : root
...@@ -18,7 +18,7 @@ parameters: ...@@ -18,7 +18,7 @@ parameters:
secret : ThisTokenIsNotSoSecretChangeIt secret : ThisTokenIsNotSoSecretChangeIt
teacher_mail : Mikael.Salson@univ-lille1.fr teacher_mail : Mikael.Salson@univ-lille1.fr
alecsia.lille1.teacherbook: http://172.18.0.3/teacherbook/index.php alecsia.lille1.teacherbook: http://172.19.0.3/teacherbook/index.php
alecsia.lille1.user.yaml: alecsia.lille1.user.yaml:
alecsia.upload_dir: %kernel.root_dir%/../upload alecsia.upload_dir: %kernel.root_dir%/../upload
......
...@@ -7,13 +7,25 @@ services: ...@@ -7,13 +7,25 @@ services:
build: './alecsia' build: './alecsia'
ports: ports:
- '8000:8000' - '8000:8000'
networks:
alecsia_net:
ipv4_address: 172.19.0.2
depends_on: depends_on:
- mysql-db - mysql-db
mysql-db: mysql-db:
build: './mysql-db' build: './mysql-db'
ports: ports:
- '80:80' - '80:80'
networks:
alecsia_net:
ipv4_address: 172.19.0.3
command: --default-authentication-plugin=mysql_native_password command: --default-authentication-plugin=mysql_native_password
restart: always restart: always
environment: environment:
MYSQL_ROOT_PASSWORD: root MYSQL_ROOT_PASSWORD: root
networks:
alecsia_net:
ipam:
driver: default
config:
- subnet: 172.19.0.0/29
\ No newline at end of file
FROM mysql FROM mysql
RUN apt-get update && apt-get install -y wget unzip php ARG MYSQL_ROOT_PASSWORD=root
RUN apt-get update && apt-get install -y wget unzip php curl
RUN curl -sS https://getcomposer.org/installer | php RUN curl -sS https://getcomposer.org/installer | php
RUN mv composer.phar /usr/local/bin/composer RUN mv composer.phar /usr/local/bin/composer
RUN mkdir /app # RUN mkdir /app
WORKDIR /app WORKDIR /var/www/html
RUN wget https://framagit.org/mikaels/teacherbook/-/archive/master/teacherbook-master.zip RUN wget https://framagit.org/mikaels/teacherbook/-/archive/master/teacherbook-master.zip
RUN unzip teacherbook-master.zip RUN unzip teacherbook-master.zip
RUN mv teacherbook-master teacherbook RUN mv teacherbook-master teacherbook
WORKDIR teacherbook WORKDIR /var/www/html/teacherbook
RUN composer install RUN composer install
RUN mysql -u root -e "CREATE DATABASE alecsia_legacy" && mysql -u root alecsia_legacy < dump.sql # RUN mysql -u root -e "CREATE DATABASE alecsia_legacy" && mysql -u root alecsia_legacy < dump.sql
RUN cp config.php.example config.php
\ No newline at end of file
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment