diff options
| author | schneefux <schneefux+commit@schneefux.xyz> | 2017-03-12 18:22:32 +0100 |
|---|---|---|
| committer | schneefux <schneefux+commit@schneefux.xyz> | 2017-03-12 18:22:32 +0100 |
| commit | 95e83d5d423323e8178d5a5526d7957dbc9143f1 (patch) | |
| tree | f21802c26c46994127546ce8c54ca2a2fcccd64d | |
| parent | 5ce83a22303a759ae3b26b1f901fbb9bad232f88 (diff) | |
| download | vaindock-95e83d5d423323e8178d5a5526d7957dbc9143f1.tar.gz vaindock-95e83d5d423323e8178d5a5526d7957dbc9143f1.zip | |
add analyzer
| -rw-r--r-- | docker-compose.yml | 20 | ||||
| -rw-r--r-- | python/Dockerfile | 22 | ||||
| -rw-r--r-- | python/requirements.txt | 5 |
3 files changed, 44 insertions, 3 deletions
diff --git a/docker-compose.yml b/docker-compose.yml index 4f51307..79d4989 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -182,6 +182,26 @@ services: - POSTGRESQL_DEST_USER=vainweb - POSTGRESQL_DEST_PASSWORD=vainweb +### Python Container for analyzer + analyzer: + build: ./python + volumes: + - ../analyzer:/apps/api + links: + - vaindock_postgres_raw + - vaindock_postgres_web + environment: + - POSTGRESQL_SOURCE_HOST=vaindock_postgres_raw + - POSTGRESQL_SOURCE_PORT=5432 + - POSTGRESQL_SOURCE_DB=vainsocial-raw + - POSTGRESQL_SOURCE_USER=vainraw + - POSTGRESQL_SOURCE_PASSWORD=vainraw + - POSTGRESQL_DEST_HOST=vaindock_postgres_web + - POSTGRESQL_DEST_PORT=5432 + - POSTGRESQL_DEST_DB=vainsocial-web + - POSTGRESQL_DEST_USER=vainweb + - POSTGRESQL_DEST_PASSWORD=vainweb + ### PostgreSQL Container - Web #################################### diff --git a/python/Dockerfile b/python/Dockerfile index a59cc2c..ef16764 100644 --- a/python/Dockerfile +++ b/python/Dockerfile @@ -1,5 +1,23 @@ -FROM python:3.6-alpine +FROM python:3.6 ADD requirements.txt / -RUN apk add --no-cache ca-certificates gcc linux-headers build-base + +RUN apt-get update && apt-get install -y --no-install-recommends \ + build-essential \ + curl \ + libfreetype6-dev \ + libpng12-dev \ + libzmq3-dev \ + pkg-config \ + rsync \ + software-properties-common \ + unzip \ + && \ + apt-get clean && \ + rm -rf /var/lib/apt/lists/* + +RUN pip --no-cache-dir install numpy + RUN pip install -r /requirements.txt +#RUN pip install tensorflow==1.0.1 +RUN pip install --upgrade https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-1.0.1-cp36-cp36m-linux_x86_64.whl CMD ["python3", "/apps/api/api.py"] diff --git a/python/requirements.txt b/python/requirements.txt index 7d8614e..7eb6f20 100644 --- a/python/requirements.txt +++ b/python/requirements.txt @@ -1,10 +1,13 @@ aiohttp==1.2.0 appdirs==1.4.0 async-timeout==1.1.0 -asyncpg==0.8.4 chardet==2.3.0 multidict==2.1.4 packaging==16.8 pyparsing==2.1.10 six==1.10.0 yarl==0.9.0 +asyncpg==0.9.0 +numpy==1.12.0 +protobuf==3.2.0 +psycopg2==2.7 |
