-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #104 from GSA/add-gunicorn-server
Adds Gunicorn WSGI web server
- Loading branch information
Showing
18 changed files
with
560 additions
and
206 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# --------------------------------------------------------------------------- | ||
|
||
# | ||
# This file configures the New Relic Python Agent. | ||
# | ||
# The path to the configuration file should be supplied to the function | ||
# newrelic.agent.initialize() when the agent is being initialized. | ||
# | ||
# The configuration file follows a structure similar to what you would | ||
# find for Microsoft Windows INI files. For further information on the | ||
# configuration file format see the Python ConfigParser documentation at: | ||
# | ||
# http://docs.python.org/library/configparser.html | ||
# | ||
# For further discussion on the behaviour of the Python agent that can | ||
# be configured via this configuration file see: | ||
# | ||
# http://newrelic.com/docs/python/python-agent-configuration | ||
# | ||
|
||
# --------------------------------------------------------------------------- | ||
|
||
# Here are the settings that are common to all environments. | ||
|
||
[newrelic] | ||
error_collector.expected_classes = werkzeug.exceptions:Forbidden werkzeug.exceptions:MethodNotAllowed |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
services: | ||
app: | ||
command: ./harvest-admin-start.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# gunicorn prior to version 20.1.0 discloses "server" header | ||
# https://github.com/GSA/datagov-deploy/issues/2826 | ||
import gunicorn | ||
|
||
gunicorn.SERVER_SOFTWARE = "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/bin/bash | ||
|
||
DIR="$(dirname "${BASH_SOURCE[0]}")" | ||
|
||
exec newrelic-admin run-program gunicorn "wsgi:application" --config "$DIR/gunicorn.conf.py" -b "0.0.0.0:$PORT" --chdir $DIR --timeout 120 --worker-class gevent --workers 8 --forwarded-allow-ips='*' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
2d505fe
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.