From 8a42a8a54e72039cf4e1957a075d66551705d70d Mon Sep 17 00:00:00 2001 From: Feisal Date: Mar 07 2019 14:41:58 +0000 Subject: [PATCH 1/2] remove docker alternative for the project --- diff --git a/artwork/envelope.sublime-workspace b/artwork/envelope.sublime-workspace new file mode 100644 index 0000000..6c21c2e --- /dev/null +++ b/artwork/envelope.sublime-workspace @@ -0,0 +1,164 @@ +{ + "auto_complete": + { + "selected_items": + [ + ] + }, + "buffers": + [ + ], + "build_system": "", + "build_system_choices": + [ + ], + "build_varint": "", + "command_palette": + { + "height": 0.0, + "last_filter": "", + "selected_items": + [ + ], + "width": 0.0 + }, + "console": + { + "height": 0.0, + "history": + [ + ] + }, + "distraction_free": + { + "menu_visible": true, + "show_minimap": false, + "show_open_files": false, + "show_tabs": false, + "side_bar_visible": false, + "status_bar_visible": false + }, + "file_history": + [ + ], + "find": + { + "height": 0.0 + }, + "find_in_files": + { + "height": 0.0, + "where_history": + [ + ] + }, + "find_state": + { + "case_sensitive": false, + "find_history": + [ + ], + "highlight": true, + "in_selection": false, + "preserve_case": false, + "regex": false, + "replace_history": + [ + ], + "reverse": false, + "show_context": true, + "use_buffer2": true, + "whole_word": false, + "wrap": true + }, + "groups": + [ + { + "sheets": + [ + ] + } + ], + "incremental_find": + { + "height": 0.0 + }, + "input": + { + "height": 0.0 + }, + "layout": + { + "cells": + [ + [ + 0, + 0, + 1, + 1 + ] + ], + "cols": + [ + 0.0, + 1.0 + ], + "rows": + [ + 0.0, + 1.0 + ] + }, + "menu_visible": true, + "output.find_results": + { + "height": 0.0 + }, + "pinned_build_system": "", + "project": "envelope.sublime-project", + "replace": + { + "height": 0.0 + }, + "save_all_on_build": true, + "select_file": + { + "height": 0.0, + "last_filter": "", + "selected_items": + [ + ], + "width": 0.0 + }, + "select_project": + { + "height": 0.0, + "last_filter": "", + "selected_items": + [ + ], + "width": 0.0 + }, + "select_symbol": + { + "height": 0.0, + "last_filter": "", + "selected_items": + [ + ], + "width": 0.0 + }, + "selected_group": 0, + "settings": + { + }, + "show_minimap": true, + "show_open_files": false, + "show_tabs": true, + "side_bar_visible": true, + "side_bar_width": 150.0, + "status_bar_visible": true, + "template_settings": + { + } +} diff --git a/docs/index.rst b/docs/index.rst index c4422c0..9fa593c 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -15,4 +15,3 @@ For more detailed information, see the specific pages below: setup/authentication model faq - diff --git a/docs/setup/development.rst b/docs/setup/development.rst index 680f922..11ff7f7 100644 --- a/docs/setup/development.rst +++ b/docs/setup/development.rst @@ -48,40 +48,11 @@ In order to run the script, simply type ``./t`` in the Docker container's shell. Integration tests are run via the following command: ``docker-compose exec web ./manage.py test -v 2 -p integration_test*.py --settings=happinesspackets.settings.tsting`` -Alternatives to Docker -====================== - -Should you be unable to run Docker, or prefer to not use it, there is an alternative way of setting up a development environment. - -0. (Optional) Use a virtual environment solution, like virtualenv or Pipenv, in order to prevent dependency conflicts with other projects. -1. Install the development packages: ``pip install -r /requirements/dev.txt`` (Pipenv users can use pipenv install) -2. Export the development settings module as an environment variable: ``export DJANGO_SETTINGS_MODULE=happinesspackets.settings.dev`` -3. Generate the client_secrets.json file (This is needed in order for login functionality to work): ``./generate_client_secrets.sh``. - If you get a permission denied error, change the file to an executable: ``chmod +x generate_client_secrets.sh`` -4. Collect static resources: ``python manage.py collectstatic`` -5. Ensure the database is up to date by running all migrations: ``python manage.py migrate`` - -In order to ensure the server is fully functional, Redis and Celery must both be configured. - -Redis ------- - -1. Install redis from your package manager, or follow the instructions on the Redis website. -2. Ensure that the redis server has been started: ``redis-server`` - -Celery -_______ - -1. Start the celery worker in the background, or in a separate terminal window: ``celery -A happinesspackets worker -l info`` - - -The tests can be run directly from the project folder as described in the Using Docker section, without having to run ``docker-compose exec web sh`` beforehand. - -As a reference: - -- Run tests with testing settings, and produce coverage report: ``./t`` -- Run integration tests: ``./manage.py test -v 2 -p integration_test*.py --settings=happinesspackets.settings.tsting`` +Important Note +=============== +Currently the project has docker installation option only. Option to set up the project with pip environment has been removed and should not be used to set up the project. this is because the project will likely use Docker in the later future and hence using pip environment may bring some crushes in the later deployment -The web server can thus be run via the ``manage.py`` script: ``python manage.py runserver 0.0.0.0:8000`` +what is you already used the pip environment? +=============== +Deactivate the environment and start installing Docker and Docker-ComposeSSSSS -When the source code is changed, the web server should automatically reload, and apply the new changes. From a51b505ff2801b956c4ec8b363d21c2569d55104 Mon Sep 17 00:00:00 2001 From: Feisal Date: Mar 07 2019 14:46:16 +0000 Subject: [PATCH 2/2] remove sublime files --- diff --git a/artwork/envelope.sublime-workspace b/artwork/envelope.sublime-workspace deleted file mode 100644 index 6c21c2e..0000000 --- a/artwork/envelope.sublime-workspace +++ /dev/null @@ -1,164 +0,0 @@ -{ - "auto_complete": - { - "selected_items": - [ - ] - }, - "buffers": - [ - ], - "build_system": "", - "build_system_choices": - [ - ], - "build_varint": "", - "command_palette": - { - "height": 0.0, - "last_filter": "", - "selected_items": - [ - ], - "width": 0.0 - }, - "console": - { - "height": 0.0, - "history": - [ - ] - }, - "distraction_free": - { - "menu_visible": true, - "show_minimap": false, - "show_open_files": false, - "show_tabs": false, - "side_bar_visible": false, - "status_bar_visible": false - }, - "file_history": - [ - ], - "find": - { - "height": 0.0 - }, - "find_in_files": - { - "height": 0.0, - "where_history": - [ - ] - }, - "find_state": - { - "case_sensitive": false, - "find_history": - [ - ], - "highlight": true, - "in_selection": false, - "preserve_case": false, - "regex": false, - "replace_history": - [ - ], - "reverse": false, - "show_context": true, - "use_buffer2": true, - "whole_word": false, - "wrap": true - }, - "groups": - [ - { - "sheets": - [ - ] - } - ], - "incremental_find": - { - "height": 0.0 - }, - "input": - { - "height": 0.0 - }, - "layout": - { - "cells": - [ - [ - 0, - 0, - 1, - 1 - ] - ], - "cols": - [ - 0.0, - 1.0 - ], - "rows": - [ - 0.0, - 1.0 - ] - }, - "menu_visible": true, - "output.find_results": - { - "height": 0.0 - }, - "pinned_build_system": "", - "project": "envelope.sublime-project", - "replace": - { - "height": 0.0 - }, - "save_all_on_build": true, - "select_file": - { - "height": 0.0, - "last_filter": "", - "selected_items": - [ - ], - "width": 0.0 - }, - "select_project": - { - "height": 0.0, - "last_filter": "", - "selected_items": - [ - ], - "width": 0.0 - }, - "select_symbol": - { - "height": 0.0, - "last_filter": "", - "selected_items": - [ - ], - "width": 0.0 - }, - "selected_group": 0, - "settings": - { - }, - "show_minimap": true, - "show_open_files": false, - "show_tabs": true, - "side_bar_visible": true, - "side_bar_width": 150.0, - "status_bar_visible": true, - "template_settings": - { - } -} diff --git a/docs/setup/development.rst b/docs/setup/development.rst index 11ff7f7..ede7a3b 100644 --- a/docs/setup/development.rst +++ b/docs/setup/development.rst @@ -54,5 +54,5 @@ Currently the project has docker installation option only. Option to set up the what is you already used the pip environment? =============== -Deactivate the environment and start installing Docker and Docker-ComposeSSSSS +Deactivate the environment and start installing Docker and Docker-Compose