Skip to content

Commit

Permalink
Merge pull request #81 from seung-lab/split_service
Browse files Browse the repository at this point in the history
Split service
  • Loading branch information
fcollman authored Mar 6, 2024
2 parents ae963f1 + 748ef44 commit c930a2a
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 17 deletions.
6 changes: 4 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
FROM tiangolo/uwsgi-nginx-flask:python3.7
FROM tiangolo/uwsgi-nginx-flask:python3.11

ENV UWSGI_INI ./uwsgi.ini
RUN python -m pip install --upgrade pip

RUN mkdir -p /home/nginx/.cloudvolume/secrets && chown -R nginx /home/nginx && usermod -d /home/nginx -s /bin/bash nginx

COPY requirements.txt /app/.
COPY requirements_service.txt /app/.

RUN pip install numpy && \
pip install -r requirements.txt
pip install -r requirements.txt && \
pip install -r requirements_service.txt
COPY . /app
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
include requirements.txt
include test_requirements.txt
include requirements_service.txt
include emannotationschemas/migrations/alembic.ini
17 changes: 4 additions & 13 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,17 +1,8 @@
Flask
geoalchemy2>=0.11.1, <0.12.0
marshmallow==3.5.1
marshmallow-jsonschema==0.10.0
pandas>=1.0.3
psycopg2-binary==2.9.1
python-dateutil==2.8.1
pytz
SQLAlchemy<1.4
flask_cors
flask-admin
flask-restx
flask-accepts
numpy>=1.18.4
shapely
jsonschema<4.0
Werkzeug <= 2.1.2
SQLAlchemy<1.4
shapely==2.0.3
geoalchemy2>=0.11.1, <0.12.0

8 changes: 8 additions & 0 deletions requirements_service.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
Flask==2.1.3
psycopg2-binary==2.9.1
flask_cors==4.0.0
flask-admin==1.6.1
flask-restx==1.3.0
flask-accepts==0.18.4
Werkzeug <= 2.1.2
pandas==2.0.3
7 changes: 5 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,14 @@ def find_version(*file_paths):
return version_match.group(1)
raise RuntimeError("Unable to find version string.")


with open('requirements.txt', 'r') as f:
required = f.read().splitlines()

with open('test_requirements.txt', 'r') as f:
test_required = f.read().splitlines()

with open('requirements_service.txt', 'r') as f:
required_service = f.read().splitlines()

setup(
version=find_version("emannotationschemas", "__init__.py"),
Expand All @@ -35,9 +36,11 @@ def find_version(*file_paths):
author='Forrest Collman',
author_email='[email protected]',
url='https://github.com/fcollman/EMAnnotationSchemas',
python_requires='>=3.8',
packages=find_packages(),
include_package_data=True,
install_requires=required,
setup_requires=['pytest-runner'],
tests_require=test_required
tests_require=test_required+required_service,
extras_require={'service': required_service},
)

0 comments on commit c930a2a

Please sign in to comment.