Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
gargantext
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
humanities
gargantext
Commits
30804572
Commit
30804572
authored
Apr 19, 2016
by
delanoe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[FIX] Docker file for installation.
parent
d2e1a70d
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
109 additions
and
90 deletions
+109
-90
TODO
graphExplorer/static/TODO
+0
-0
asRoot.sh
install/debian/asRoot.sh
+2
-0
Dockerfile
install/docker/dev/Dockerfile
+96
-86
install.sh
install/docker/dev/install.sh
+9
-3
requirements.txt
install/docker/dev/requirements.txt
+1
-0
menu.html
templates/pages/menu.html
+1
-1
No files found.
graphExplorer/static/TODO
100755 → 100644
View file @
30804572
File mode changed from 100755 to 100644
install/debian/asRoot.sh
View file @
30804572
...
@@ -47,6 +47,8 @@ apt-get update && apt-get install -y \
...
@@ -47,6 +47,8 @@ apt-get update && apt-get install -y \
for
dir
in
"/srv/gargantext"
\
for
dir
in
"/srv/gargantext"
\
"/srv/gargantext_lib"
\
"/srv/gargantext_lib"
\
"/srv/gargantext_static"
\
"/srv/gargantext_media"
\
"/srv/env_3-5"
\
"/srv/env_3-5"
\
"/var/www/gargantext"
;
do
\
"/var/www/gargantext"
;
do
\
mkdir
$dir
mkdir
$dir
...
...
install/docker/dev/Dockerfile
View file @
30804572
#FROM debian:stretch
###########################################################
FROM
gargantext
# ____ ____ _____ __ ___ #
#MAINTAINER ISCPIF <alexandre.delanoe@iscpif.fr>
# / ___| __ _ _ __ / ___| __ _ _ _|_ _|__\ \/ / |_ #
#
# | | _ / _` | '__| | _ / _` | '_ \| |/ _ \\ /| __| #
## Install docker.io
# | |_| | (_| | | | |_| | (_| | | | | | __// \| |_ #
## Install sudo
# \____|\__,_|_| \____|\__,_|_| |_|_|\___/_/\_\\__| #
## wget http://dl.gargantext.
# #
## cd /srv/gargantext/install
###########################################################
## sudo docker build -t gargantext .
# docker run -i -t gargantext /bin/bash
######################################################################
FROM
debian:stretch
#FROM gargantext
MAINTAINER
ISCPIF <alexandre.delanoe@iscpif.fr>
######################################################################
USER
root
USER
root
# RUN apt-get update && \
RUN
apt-get update
&&
\
# apt-get install -y \
apt-get
install
-y
\
# apt-utils ca-certificates locales \
apt-utils ca-certificates locales
\
# sudo aptitude gcc wget git postgresql-9.5 vim
sudo
aptitude gcc g++ wget git postgresql-9.5 vim
#
# ## Configure timezone and locale
## Configure timezone and locale
# RUN echo "Europe/Paris" > /etc/timezone && \
RUN
echo
"Europe/Paris"
>
/etc/timezone
&&
\
# dpkg-reconfigure -f noninteractive tzdata && \
dpkg-reconfigure
-f
noninteractive tzdata
&&
\
# sed -i -e 's/# en_GB.UTF-8 UTF-8/en_GB.UTF-8 UTF-8/' /etc/locale.gen && \
sed
-i
-e
's/# en_GB.UTF-8 UTF-8/en_GB.UTF-8 UTF-8/'
/etc/locale.gen
&&
\
# sed -i -e 's/# fr_FR.UTF-8 UTF-8/fr_FR.UTF-8 UTF-8/' /etc/locale.gen && \
sed
-i
-e
's/# fr_FR.UTF-8 UTF-8/fr_FR.UTF-8 UTF-8/'
/etc/locale.gen
&&
\
# echo 'LANG="fr_FR.UTF-8"' > /etc/default/locale && \
echo
'LANG="fr_FR.UTF-8"'
>
/etc/default/locale
&&
\
# dpkg-reconfigure --frontend=noninteractive locales && \
dpkg-reconfigure
--frontend
=
noninteractive locales
&&
\
# update-locale LANG=fr_FR.UTF-8
update-locale
LANG
=
fr_FR.UTF-8
#
#
## Install Database, main dependencies and Python
# RUN apt-get update \
## (installing some Debian version before pip to get dependencies)
# && apt-get install -y postgresql-server-dev-9.5 \
RUN
apt-get update
&&
apt-get
install
-y
\
# libpq-dev libxml2 libxml2-dev xml-core libgfortran-5-dev
postgresql-server-dev-9.5 libpq-dev libxml2
\
#
libxml2-dev xml-core libgfortran-5-dev
\
# # PROD VERSION OF GARGANTEXt
virtualenv python3-virtualenv
\
# # RUN apt-get install uwsgi nginx
python3.4 python3.4-dev
\
#
python3.5 python3.5-dev
\
#
python3-six python3-numpy python3-setuptools
\
# ^for numpy, pandas
python3-numexpr \
# ^ for numpy performance
libxml2-dev libxslt-dev
# ^ for lxml
## PROD VERSION OF GARGANTEXT ONLY
#RUN apt-get install -y uwsgi nginx uwsgi-plugin-python rabbitmq-server
# ## CREATE USER and adding it to sudo
# ## CREATE USER and adding it to sudo
# ## TODO ask user for password
# ## TODO ask user for password
# RUN adduser --disabled-password --gecos "" gargantua
RUN
adduser
--disabled-password
--gecos
""
gargantua
# RUN apt-get install -y sudo && adduser gargantua sudo \
RUN
apt-get
install
-y
sudo
&&
adduser gargantua
sudo
\
# && echo '%sudo ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
&&
echo
'%sudo ALL=(ALL) NOPASSWD:ALL'
>>
/etc/sudoers
#
# # Python dependencies
# # (installing Debian version before pip to get dependencies)
# # TODO: update it with requirements.txt
# RUN apt-get update && apt-get install -y \
# virtualenv python3-virtualenv \
# python3.4 python3.4-dev \
# python3.5 python3.5-dev \
# python3-six python3-numpy
#
# # Installing pip version of python libs
WORKDIR
/home/gargantua
# FIXME : pip install -r all requirements does not work, need to split the list
#RUN wget http://dl.delanoe.org/requirements.txt \
# && /usr/bin/virtualenv --py=/usr/bin/python3.5 env_3-5 \
# && /bin/bash -c 'source env_3-5/bin/activate' \
# && /bin/bash -c 'env_3-5/bin/pip install git+https://github.com/zzzeek/sqlalchemy.git@rel_1_1' \
# && /bin/bash -c 'env_3-5/bin/pip install -r requirements.txt'
# chown gargantua
# FIXME, it depends on postgres configuration
VOLUME
["/srv","/var"]
# Create directories in /srv
# FIXME: not tested
RUN for
dir
in
"/srv/gargantext"
\
"/srv/gargantext_lib"
\
"/srv/gargantext_static"
\
"/srv/gargantext_media"
\
"/srv/env_3-5"
\
"/var/www/gargantext"
;
do
\
mkdir
-p
$dir
\
chown
gargantua:gargantua
$dir
\
done
\
echo
"Root: END of the installation of Gargantext by Root."
#
#
#####################################################################
## CONFIGURE POSTGRESQL
## CONFIGURE POSTGRESQL
#
######################################################################
#VOLUME ["/home/gargantua","/data/gargantext"]
## INSTALL MAIN DEPENDENCIES
#WORKDIR /srv
#RUN mkdir -p gargantext
# configure postgres here
# OK
USER
postgres
USER
postgres
RUN
/etc/init.d/postgresql start
&&
\
RUN
/etc/init.d/postgresql start
&&
\
psql -c "CREATE user gargantua WITH PASSWORD 'C8kdcUrAQy66U'" &&\
psql -c "CREATE user gargantua WITH PASSWORD 'C8kdcUrAQy66U'" &&\
createdb -O gargantua gargandb
createdb -O gargantua gargandb \
&& echo "Root: END of the installation of Gargantexts Database by postgres."
#
GET CONFIG FILES
#
#####################################################################
#
USER gargantua
#
# INSTALL MAIN DEPENDENCIES
#
RUN wget http://dl.delanoe.org/gargantext_big.txt -o /srv/gargantext_big.txt
#
#####################################################################
#RUN cd /srv/ && git clone https://gogs.iscpif.fr/gargantext.git
USER
gargantua
# TODO (soon) : git clone https://gogs.iscpif.fr/gargantext.git
RUN
git clone ssh://gitolite@delanoe.org:1979/gargantext /srv/gargantext
\
&&
cd
/srv/gargantext
\
&&
git fetch origin refactoring
\
&&
git checkout refactoring
# script pour peupler la base
# mount /srv
# Possible FIXME : if `pip install -r requirements.txt` fails
# execute
# then: fixme >> maybe (split the list)
# else: enjoy
##################### INSTALLATION END #####################
# # Installing pip version of python libs
# TODO: user local file requirements with docker (and not wget)
# Expose the default port
RUN
wget http://dl.delanoe.org/requirements.txt
-o
/tmp/requirements.txt
\
#EXPOSE 54332
&&
/usr/bin/virtualenv
--py
=
/usr/bin/python3.5 env_3-5
\
&&
/bin/bash
-c
'source env_3-5/bin/activate'
\
&&
/bin/bash
-c
'env_3-5/bin/pip install git+https://github.com/zzzeek/sqlalchemy.git@rel_1_1'
\
&&
/bin/bash
-c
'env_3-5/bin/pip install -r /tmp/requirements.txt'
# Default port to execute the entrypoint (MongoDB)
#CMD ["--port 27017"]
# Set default container command
# GET CONFIG FILES
#ENTRYPOINT usr/bin/mongod
WORKDIR
/tmp
# ENTRYPOINT /etc/init.d/postgresql start
RUN
wget http://dl.gargantext.org/gargantext_lib.tar.bz2
\
&&
tar
xvjf gargantext_lib.tar.bz2
-o
/srv/gargantext_lib
\
&&
chown
-R
gargantua:gargantua /srv/gargantext_lib
\
&&
echo
"Root: END of the installation of Gargantexts Database by postgres."
# TODO script pour peupler la base
######################################################################
######################################################################
install/docker/dev/install.sh
View file @
30804572
#/bin/bash
#/bin/bash
# in progress
## Quick Manual
## Install docker.io && sudo
## sudo docker build -t gargantext .
## docker run -i -t gargantext /bin/bash
# Install Docker
# Install Docker
# Debian/Ubuntu: apt-get install docker
# Debian/Ubuntu: apt-get install docker
# run turboparser port, with python 3.4
# run turboparser port, with python 3.4
#docker run -d -p 8000:8000 -v /srv:/srv -t gargantext python /srv/gargantext/gargantext.py
#docker run -d -p 8000:8000 -v /srv:/srv -t gargantext python /srv/gargantext/gargantext.py
# launch
# launch
#cd /srv/gargantext
#cd /srv/gargantext
#source /srv/env_3-5/bin/activate &&
#source /srv/env_3-5/bin/activate &&
#docker run -d -p 8000:8000 -v /srv:/srv -t gargantext python /srv/gargantext/gargantext.py
#docker run -d -p 8000:8000 -v /srv:/srv -t gargantext python /srv/gargantext/gargantext.py
docker build
-t
gargantext
.
sudo
docker build
-t
gargantext
.
install/docker/dev/requirements.txt
0 → 120000
View file @
30804572
../../python/requirements.txt
\ No newline at end of file
templates/pages/menu.html
View file @
30804572
...
@@ -155,7 +155,7 @@
...
@@ -155,7 +155,7 @@
<footer>
<footer>
<p>
<p>
Gargantext, version
2
.0,
Gargantext, version
3.0
.0,
<a
href=
"http://www.cnrs.fr"
target=
"blank"
title=
"Institution that enables this project."
>
<a
href=
"http://www.cnrs.fr"
target=
"blank"
title=
"Institution that enables this project."
>
Copyrights CNRS {{ date.year }}
Copyrights CNRS {{ date.year }}
</a>
</a>
...
...
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