Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
jlopez
wicopa
Commits
a40f526c
Commit
a40f526c
authored
Apr 09, 2019
by
remy
Browse files
Adding Dockerfiles
parent
b1800eea
Changes
6
Hide whitespace changes
Inline
Side-by-side
.dockerweb/.Dockerfile.swp
→
.docker
/
web/.Dockerfile.swp
View file @
a40f526c
File moved
.dockerweb/Dockerfile
→
.docker
/
web/Dockerfile
View file @
a40f526c
...
...
@@ -10,10 +10,10 @@ RUN mkdir /app && cd /app && \
cp
wicopa/conf/Conf.php.sample wicopa/conf/Conf.php
&&
\
chown
-R
apache:apache /app
&&
\
sed
-i
"s#DB_NAME = ''#DB_NAME = 'wicopa'#"
wicopa/conf/Conf.php
&&
\
sed
-i
"s#DB_HOSTNAME = ''#DB_HOSTNAME = '
localhost
'#"
wicopa/conf/Conf.php
&&
\
sed
-i
"s#DB_HOSTNAME = ''#DB_HOSTNAME = '
wicopadb
'#"
wicopa/conf/Conf.php
&&
\
sed
-i
"s#DB_USERNAME = ''#DB_USERNAME = 'wicopauser'#"
wicopa/conf/Conf.php
&&
\
sed
-i
"s#DB_PP = ''#DB_PP = 'w1c0Pa5s'#"
wicopa/conf/Conf.php
&&
\
sed
-i
"s#
KK = ''#KK =
'450cb0c92db35549cb926efc391df2ceae4b48d1'#"
wicopa/conf/Conf.php
sed
-i
"s#
'to_replace_with_your_admin_pass'#
'450cb0c92db35549cb926efc391df2ceae4b48d1'#"
wicopa/conf/Conf.php
RUN
sed
-i
's/^#ServerName .*/ServerName localhost:80/g'
/etc/apache2/httpd.conf
&&
\
sed
-i
's#/var/www/localhost/htdocs#/app/wicopa#g'
/etc/apache2/httpd.conf
&&
\
...
...
.dockerdb/.Dockerfile.swp
deleted
100644 → 0
View file @
b1800eea
File deleted
.dockerdb/Dockerfile
deleted
100644 → 0
View file @
b1800eea
FROM
yobasystems/alpine-mariadb
# docker-entrypoint-initdb.d script failed because of the size of the inserts...
RUN
"/usr/bin/mysqld_safe --skip-grant-tables &"
&&
\
mysql
-u
root
-e
"CREATE DATABASE wicopa"
&&
\
mysql
-u
root wicopa < /tmp/wicopa.sql
INSTALL.md
View file @
a40f526c
# Installing wicopa
```
bash
git clone https://gitlab.mbb.univ-montp2.fr/jlopez/wicopa.git
apt-get
install
-y
apache2 mariadb-server php7.0 phpmyadmin libapache2-mod-php7.0 pv
a2enmod php7.0
...
...
@@ -29,4 +31,17 @@ pv wicopa.sql.gz | gunzip | mysql -u wicopauser -p wicopa
vim conf/Conf.php
```
# Using Docker
```
bash
git clone https://gitlab.mbb.univ-montp2.fr/jlopez/wicopa.git
# you need to have wicopa.sql here
wget http://web.mbb.univ-montp2.fr/download/wicopa.sql.gz
gunzip
-d
wicopa.sql.gz
mkdir
-p
/data/mysql/wicopa
docker-compose up
--build
# you can access to it at http://127.0.0.1:8000
```
docker-compose.yml
View file @
a40f526c
...
...
@@ -4,39 +4,24 @@ services:
apache
:
build
:
context
:
.
dockerfile
:
.dockerweb/Dockerfile
dockerfile
:
.docker
/
web/Dockerfile
container_name
:
wicopaweb
restart
:
always
ports
:
-
"
8000:80"
volumes
:
-
/etc/localtime:/etc/localtime:ro
networks
:
-
web
depends_on
:
-
mariadb
mariadb
:
#image: yobasystems/alpine-mariadb
build
:
context
:
.
dockerfile
:
.dockerdb/Dockerfile
image
:
mariadb:10.3
restart
:
always
container_name
:
wicopadb
volumes
:
-
/etc/localtime:/etc/localtime:ro
-
/data/mysql:/var/lib/mysql
# following failed because of the size of the inserts
#- ./wicopa.sql:/docker-entrypoint-initdb.d/wicopa.sql
-
./wicopa.sql:/tmp/wicopa.sql
-
/data/mysql/wicopa:/var/lib/mysql
-
./wicopa.sql:/docker-entrypoint-initdb.d/wicopa.sql
environment
:
TZ
:
"
Europe/Paris"
MYSQL_ROOT_PASSWORD
:
w1c0Pa5s
MYSQL_DATABASE
:
wicopa
MYSQL_USER
:
wicopauser
MYSQL_PASSWORD
:
w1c0Pa5s
networks
:
-
web
expose
:
-
"
3306"
networks
:
web
:
driver
:
bridge
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment