From b91dff8b970f45b2ba0278a8714fc884c17c2ae7 Mon Sep 17 00:00:00 2001 From: Drew Short Date: Sat, 28 Jul 2018 12:47:58 -0500 Subject: [PATCH] Added basic repository documentation --- .dockerignore | 4 ---- CONTRIBUTING.md | 6 +++++ Dockerfile | 23 ------------------- README.md | 40 +++++++++++++++++++++++++++++++++ server/.dockerignore | 11 +++++++++ server/CHANGELOG.md | 0 server/Dockerfile | 4 +++- server/README.md | 53 ++++++++++++++++++++++++++++++++++++++++++++ 8 files changed, 113 insertions(+), 28 deletions(-) delete mode 100644 .dockerignore create mode 100644 CONTRIBUTING.md delete mode 100644 Dockerfile create mode 100644 README.md create mode 100644 server/.dockerignore create mode 100644 server/CHANGELOG.md create mode 100644 server/README.md diff --git a/.dockerignore b/.dockerignore deleted file mode 100644 index 6644bf7..0000000 --- a/.dockerignore +++ /dev/null @@ -1,4 +0,0 @@ -server/instance/ -server/setup.py -server/test/ -.admin_credentials \ No newline at end of file diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..9890fed --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,6 @@ +# Contributing + +* Fork the repository +* Make changes +* Test everything +* Open issue and attach patchfile for changes \ No newline at end of file diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index 582ded4..0000000 --- a/Dockerfile +++ /dev/null @@ -1,23 +0,0 @@ -FROM python:3.6-slim-stretch -MAINTAINER Drew Short - -ENV ATHENEUM_APP_DIRECTORY /opt/atheneum -ENV ATHENEUM_CONFIG_DIRECTORY /srv/atheneum/config -ENV ATHENEUM_DATA_DIRECTORY /srv/atheneum/data - -RUN mkdir -p ${ATHENEUM_APP_DIRECTORY} \ -&& mkdir -p ${ATHENEUM_CONFIG_DIRECTORY} \ -&& mkdir -p ${ATHENEUM_DATA_DIRECTORY} \ -&& pip install pipenv gunicorn - -VOLUME ${ATHENEUM_CONFIG_DIRECTORY} -VOLUME ${ATHENEUM_DATA_DIRECTORY} - -COPY ./server/ ${ATHENEUM_APP_DIRECTORY}/ - -RUN cd ${ATHENEUM_APP_DIRECTORY} \ -&& pipenv install --system --deploy --ignore-pipfile - -WORKDIR ${ATHENEUM_APP_DIRECTORY} - -CMD ./entrypoint.sh diff --git a/README.md b/README.md new file mode 100644 index 0000000..5187763 --- /dev/null +++ b/README.md @@ -0,0 +1,40 @@ +# Atheneum + +An ebook/comic library service and web client. + +## Parts + +### Server + +The core API server + +More information available at server/README.md + +### Client + +The primary SPA frontend + +More information available at client/README.md + +### Administration + +The administration SPA. + +More information available at administration/README.md + +## Release History + +## Changelog + +See: +* server/CHANGELOG.md +* client/CHANGELOG.md +* administration/CHANGELOG.md + +## FAQ + +* TODO + +## Maintainers + +* Drew Short \ No newline at end of file diff --git a/server/.dockerignore b/server/.dockerignore new file mode 100644 index 0000000..281f6d5 --- /dev/null +++ b/server/.dockerignore @@ -0,0 +1,11 @@ +.admin_credentials +.coverage +.pylintrc +mypy.ini +run_tests.sh +setup.py +test_settings.py +.mypy_cache/ +.pytest_cache/ +instance/ +tests/ diff --git a/server/CHANGELOG.md b/server/CHANGELOG.md new file mode 100644 index 0000000..e69de29 diff --git a/server/Dockerfile b/server/Dockerfile index 582ded4..6b34125 100644 --- a/server/Dockerfile +++ b/server/Dockerfile @@ -13,11 +13,13 @@ RUN mkdir -p ${ATHENEUM_APP_DIRECTORY} \ VOLUME ${ATHENEUM_CONFIG_DIRECTORY} VOLUME ${ATHENEUM_DATA_DIRECTORY} -COPY ./server/ ${ATHENEUM_APP_DIRECTORY}/ +COPY ./ ${ATHENEUM_APP_DIRECTORY}/ RUN cd ${ATHENEUM_APP_DIRECTORY} \ && pipenv install --system --deploy --ignore-pipfile +EXPOSE 8080 + WORKDIR ${ATHENEUM_APP_DIRECTORY} CMD ./entrypoint.sh diff --git a/server/README.md b/server/README.md new file mode 100644 index 0000000..cd9d569 --- /dev/null +++ b/server/README.md @@ -0,0 +1,53 @@ +# Atheneum Server + +## Requirements + +* Python 3.6 +* Pipenv + +## Installation + +```bash +git clone +cd +pipenv install +pipenv shell +``` + +## Configuration + +## Running + +### Docker + +```bash +docker build -t atheneum:local-test . +docker run -d atheneum:local-test +``` + +### Local Development Version + +```bash +FLASK_APP=atheneum:atheneum flask run +``` + +## FAQ + +## Development + +```bash +pipenv install --dev +``` + +* Make changes +* Add/Update tests + +```bash +./run_tests +``` + +* If everything passes follow contributing guide. + +## Contributing + +See ../CONTRIBUTING.md \ No newline at end of file