Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
set -eu
if [ "${MODE}" == "development" ]; then
if [ -f /app/requirements.txt ]; then pip install -r /app/requirements.txt; fi
exec python web.py
exec flask --app web.py run --debug --port 80 --host "0.0.0.0"
else
exec gunicorn -k egg:meinheld#gunicorn_worker -c "$GUNICORN_CONF" "$APP_MODULE"
fi
7 changes: 2 additions & 5 deletions web.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,8 @@

# Import the app from the service consuming the template
app_file = os.environ.get('APP_ENTRYPOINT')
try:
module_path = 'ext.app.{}'.format(app_file)
import_module(module_path)
except Exception:
helpers.logger.exception('Exception raised when importing app code')
module_path = 'ext.app.{}'.format(app_file)
import_module(module_path)

#######################
## Start Application ##
Expand Down