Closed Bug 1200604 Opened 10 years ago Closed 10 years ago

The URL Rewrite IIS module is needed to use the rest/ shortcut in URLs (instead of rest.cgi/)

Categories

(Bugzilla :: Documentation, defect)

defect
Not set
minor

Tracking

()

RESOLVED FIXED
Bugzilla 5.0

People

(Reporter: bgx, Assigned: LpSolit)

Details

Attachments

(3 files)

Attached file rewrite_rule.txt
User Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:41.0) Gecko/20100101 Firefox/41.0 Build ID: 20150827142634 Steps to reproduce: I tried out the REST API on an Bugzilla 5.0 installed on Windows Server 2012 with IIS. Test call was "example.com/rest/version" with Firefox 41. Actual results: The Webserver returned a 404 Error. It didn't map the request to rest.cgi. Expected results: Expected was a html formatted json output. A workaround would be accessing the API via example.com/rest.cgi/version. The better option would be to add a URL rewrite rule to IIS. See the attachment. See should also be mentioned in docs regarding the installation of Bugzilla on Windows with IIS.
In which file do you have to copy these rewrite rules for IIS? Apache has .htaccess; what's the equivalent for IIS?
The equivalent for IIS is the web.config file in the root folder of Bugzilla. The url rewrite part has to be in the <system.webServer/> section.
To make this rule work, you must have the URL Rewrite module installed, which is not available by default: http://www.iis.net/downloads/microsoft/url-rewrite I didn't install it, because it complains that I must first install the Web Platform Installer, which I do not want to do, so I couldn't test the proposed patch.
Assignee: installation → documentation
Severity: normal → minor
Component: Installation & Upgrading → Documentation
Summary: Bugzilla on IIS - URL Rewrite needed to get REST API working → The URL Rewrite IIS module is needed to use the rest/ shortcut in URLs (instead of rest.cgi/)
At the bottom of the page mentioned above, there is a link to directly download the extension, which doesn't require the Web Platform Installer. Once it's installed, you can click the "URL Rewrite" icon from the IIS manager. Then you click the "Add Rule(s)" link in the Actions menu and you click the "Blank rule" in the Inbound rules section. From there, you fill fields as shown in the screenshot. There is no need to restart IIS; changes are effective immediately.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Attached patch patch, v1Splinter Review
Assignee: documentation → LpSolit
Status: NEW → ASSIGNED
Attachment #8676858 - Flags: review?(gerv)
Target Milestone: --- → Bugzilla 5.0
Attachment #8676858 - Flags: review?(gerv) → review+
To ssh://gitolite3@git.mozilla.org/bugzilla/bugzilla.git 6b1b0ba..4d6f94f master -> master To ssh://gitolite3@git.mozilla.org/bugzilla/bugzilla.git 205e925..b35db6c 5.0 -> 5.0
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: