From da63fc64d06e9d166d1cd9dd57e70608f23158fc Mon Sep 17 00:00:00 2001 From: Chris Meyers Date: Wed, 21 Jan 2015 13:53:46 -0500 Subject: [PATCH] redirect to primary host with the original requesting path preserved --- awx/main/middleware.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/awx/main/middleware.py b/awx/main/middleware.py index 6cc395b458..a4b72bf91f 100644 --- a/awx/main/middleware.py +++ b/awx/main/middleware.py @@ -102,4 +102,4 @@ class HAMiddleware(object): }) # Redirect to the base page of the primary instance. - return HttpResponseRedirect('http://%s/' % primary.hostname) + return HttpResponseRedirect('http://%s%s' % (primary.hostname, request.path))