Skip to content

Commit

Permalink
Add --nostatic and --insecure args to runserver command. (#450)
Browse files Browse the repository at this point in the history
Fixes #449
  • Loading branch information
davidfb authored Jan 4, 2025
1 parent 32ac73e commit f0a3ec6
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions daphne/management/commands/runserver.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,18 @@ def add_arguments(self, parser):
"seconds (default: 5)"
),
)
parser.add_argument(
"--nostatic",
action="store_false",
dest="use_static_handler",
help="Tells Django to NOT automatically serve static files at STATIC_URL.",
)
parser.add_argument(
"--insecure",
action="store_true",
dest="insecure_serving",
help="Allows serving static files even if DEBUG is False.",
)

def handle(self, *args, **options):
self.http_timeout = options.get("http_timeout", None)
Expand Down

0 comments on commit f0a3ec6

Please sign in to comment.