INSTALL.md 1.37 KB
Newer Older
remy's avatar
remy committed
1
2
3
# Installing wicopa

```bash
remy's avatar
remy committed
4
5
git clone https://gitlab.mbb.univ-montp2.fr/jlopez/wicopa.git

remy's avatar
remy committed
6
apt-get install -y apache2 mariadb-server php7.0 phpmyadmin libapache2-mod-php7.0 pv
remy's avatar
remy committed
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22

a2enmod php7.0

cd /var/www/html/wicopa

cp conf/Conf.php.sample conf/Conf.php

chown -R www-data /var/www/html/wicopa
chmod -R o-r /var/www/html/wicopa

service apache2 restart
```

# Creating username and database

```bash
remy's avatar
remy committed
23
echo "CREATE DATABASE wicopa;" | mysql -uroot -p
remy's avatar
remy committed
24

remy's avatar
remy committed
25
26
27
echo "CREATE USER 'wicopauser'@'localhost' IDENTIFIED BY 's3cret;'"  | mysql -uroot -p

echo 'GRANT ALL PRIVILEGES ON wicopa.* TO "wicopauser"@"localhost";' | mysql -uroot -p
remy's avatar
remy committed
28

remy's avatar
remy committed
29
30
wget http://web.mbb.univ-montp2.fr/download/wicopa.sql.gz

remy's avatar
remy committed
31
pv wicopa.sql.gz | gunzip | mysql -uwicopauser -p wicopa
remy's avatar
remy committed
32
33
34
35

vim conf/Conf.php
```

remy's avatar
remy committed
36
37
38
39
40
41
42
43
# 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

44
sudo mkdir -p /data/mysql/wicopa
remy's avatar
remy committed
45

46
sudo docker-compose up --build
remy's avatar
remy committed
47
# you can access to it at http://127.0.0.1:8000
remy's avatar
remy committed
48
# you can login as "admin" with password w1c0Pa5s
remy's avatar
remy committed
49
```
remy's avatar
remy committed
50

51
Note that due to selinux problem on some RedHat-like distros, I added the `z` option to the volumes on the docker-compose file. [See here for more informations](https://www.projectatomic.io/blog/2015/06/using-volumes-with-docker-can-cause-problems-with-selinux/)