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
84482223
Commit
84482223
authored
Aug 03, 2017
by
Alexandre Delanoë
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'unstable' into testing-merge
parents
eb1aaa46
b11d72c3
Changes
8
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
47 additions
and
32 deletions
+47
-32
nodes.py
gargantext/models/nodes.py
+2
-1
db.py
gargantext/util/db.py
+4
-1
gargantext_notebook.py
gargantext_notebook.py
+1
-0
requirements.txt
install/gargamelle/requirements.txt
+1
-1
notebook.run
install/notebook.run
+11
-3
Dockerfile
install/notebook/Dockerfile
+23
-23
gargantext_notebook.py
install/notebook/gargantext_notebook.py
+2
-2
requirements.txt
install/notebook/requirements.txt
+3
-1
No files found.
gargantext/models/nodes.py
View file @
84482223
...
...
@@ -2,7 +2,8 @@ from gargantext.util.db import session
from
gargantext.util.files
import
upload
from
gargantext.constants
import
*
from
sqlalchemy_utils.types
import
TSVectorType
# Uncomment to make column full text searchable
#from sqlalchemy_utils.types import TSVectorType
from
datetime
import
datetime
...
...
gargantext/util/db.py
View file @
84482223
...
...
@@ -9,7 +9,10 @@ import sqlalchemy as sa
from
sqlalchemy.orm
import
sessionmaker
,
scoped_session
from
sqlalchemy.ext.declarative
import
declarative_base
from
sqlalchemy
import
delete
from
sqlalchemy_searchable
import
make_searchable
# To make Full Text search possible, uncomment lines below
# (and install it with pip before)
#from sqlalchemy_searchable import make_searchable
def
get_engine
():
from
sqlalchemy
import
create_engine
...
...
gargantext_notebook.py
0 → 120000
View file @
84482223
install
/
notebook
/
gargantext_notebook
.
py
\ No newline at end of file
install/gargamelle/requirements.txt
View file @
84482223
...
...
@@ -17,7 +17,7 @@ jdatetime==1.7.2
kombu==3.0.37 # messaging
langdetect==1.0.6 #detectinglanguage
nltk==3.1
numpy==1.1
0.4
numpy==1.1
3.1
psycopg2==2.6.2
pycountry==1.20
python-dateutil==2.4.2
...
...
install/notebook.run
View file @
84482223
...
...
@@ -4,12 +4,20 @@
#-v /srv/gargantext_lib:/srv/gargantext_lib \
sudo
docker
rm
$(
sudo
docker ps
-a
|
grep
notebook |
grep
sh |
awk
'{print $1}'
)
#HOSTIP=$(ip route show 0.0.0.0/0 | awk '{print $3}')
#--add-host=localhost:${HOSTIP} \
sudo
docker run
\
--name
=
garg-notebook
\
-
v
/srv/gargantext:/srv/gargantex
t
\
-
-net
=
hos
t
\
-p
8899:8899
\
--env
POSTGRES_HOST
=
localhost
\
-v
/srv/gargantext:/srv/gargantext
\
-it
garg-notebook:latest
\
/bin/bash
-c
"/bin/su notebooks -c 'source /env_3-5/bin/activate && jupyter notebook --port=8899 --ip=0.0.0.0 --no-browser --notebook-dir=/home/notebooks/'"
#/bin/bash -c "/bin/su gargantua -c 'source /env_3-5/bin/activate && jupyter notebook --port=8899 --ip=127.0.0.1 --no-browser'"
/bin/bash
-c
"/bin/su notebooks -c 'source /env_3-5/bin/activate && cd /srv/gargantext/ && jupyter notebook --port=8899 --ip=0.0.0.0 --no-browser'"
# #&& jupyter nbextension enable --py widgetsnbextension --sys-prefix
#/bin/bash -c "/bin/su notebooks -c 'source /env_3-5/bin/activate && cd /srv/gargantext/ && jupyter notebook --port=8899 --ip=0.0.0.0 --no-browser --notebook-dir=/home/notebooks/'"
install/notebook/Dockerfile
View file @
84482223
...
...
@@ -16,10 +16,10 @@ RUN apt-get update && \
apt-utils ca-certificates locales
\
sudo
aptitude gcc g++ wget git vim
\
build-essential make
\
curl
\
postgresql-9.6 postgresql-client-9.6 postgresql-contrib-9.6
\
postgresql-server-dev-9.6 libpq-dev libxml2
\
postgresql-9.6 postgresql-client-9.6 postgresql-contrib-9.6
curl
#
postgresql-9.6 postgresql-client-9.6 postgresql-contrib-9.6 \
#
postgresql-server-dev-9.6 libpq-dev libxml2 \
#
postgresql-9.6 postgresql-client-9.6 postgresql-contrib-9.6
# Install Stack
...
...
@@ -69,7 +69,7 @@ RUN virtualenv /env_3-5
RUN
echo
'alias venv="source /env_3-5/bin/activate"'
>>
~/.bashrc
# CONFIG FILES
ADD
requirements.txt /
ADD
psql_configure.sh /
#
ADD psql_configure.sh /
ADD
django_configure.sh /
RUN
.
/env_3-5/bin/activate
&&
pip3
install
-r
requirements.txt
&&
\
...
...
@@ -85,23 +85,23 @@ RUN chown notebooks:notebooks -R /env_3-5
### Notebook IHaskell and IPYTHON ENVIRONNEMENT
########################################################################
RUN
apt-get update
&&
apt-get
install
-y
\
libtinfo-dev
\
libzmq3-dev
\
libcairo2-dev
\
libpango1.0-dev
\
libmagic-dev
\
libblas-dev
\
liblapack-dev
RUN
curl
-sSL
https://get.haskellstack.org/ | sh
RUN
stack setup
RUN
git clone https://github.com/gibiansky/IHaskell
RUN
.
/env_3-5/bin/activate
\
&&
cd
IHaskell
\
&&
stack
install
gtk2hs-buildtools
\
&&
stack
install
--fast
\
&&
/root/.local/bin/ihaskell
install
--stack
#
RUN apt-get update && apt-get install -y \
#
libtinfo-dev \
#
libzmq3-dev \
#
libcairo2-dev \
#
libpango1.0-dev \
#
libmagic-dev \
#
libblas-dev \
#
liblapack-dev
#
RUN curl -sSL https://get.haskellstack.org/ | sh
#
RUN stack setup
#
RUN git clone https://github.com/gibiansky/IHaskell
#
RUN . /env_3-5/bin/activate \
#
&& cd IHaskell \
#
&& stack install gtk2hs-buildtools \
#
&& stack install --fast \
#
&& /root/.local/bin/ihaskell install --stack
#
#
########################################################################
...
...
@@ -112,6 +112,6 @@ RUN . /env_3-5/bin/activate \
#RUN echo "host all all 0.0.0.0/0 md5" >> /etc/postgresql/9.5/main/pg_hba.conf
#RUN echo "listen_addresses='*'" >> /etc/postgresql/9.5/main/postgresql.conf
EXPOSE
8899
EXPOSE
5432
8899
VOLUME
["/srv/","/home/notebooks/"]
install/notebook/gargantext_notebook.py
View file @
84482223
"""
Gargantext Software Copyright (c) 2016 CNRS ISC-PIF -
Gargantext Software Copyright (c) 2016
-2017
CNRS ISC-PIF -
http://iscpif.fr
Licence (see :
http://gitlab.iscpif.fr/humanities/gargantext/blob/stable/LICENSE )
...
...
@@ -47,7 +47,7 @@ def documents(corpus_id):
)
import
seaborn
as
sns
#
import seaborn as sns
import
pandas
as
pd
def
chart
(
docs
,
field
):
...
...
install/notebook/requirements.txt
View file @
84482223
...
...
@@ -17,7 +17,7 @@ jdatetime==1.7.2
kombu==3.0.37 # messaging
langdetect==1.0.6 #detectinglanguage
nltk==3.1
numpy==1.1
0.4
numpy==1.1
3.1
psycopg2==2.6.2
pycountry==1.20
python-dateutil==2.4.2
...
...
@@ -40,3 +40,5 @@ jupyter-console==5.1.0
jupyter-core==4.3.0
ipython==5.2.0
ipython-genutils==0.1.0
ipywidgets
matplotlib==2.0.2
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