#1265: Support for IIS7
-------------------------+--------------------------------------------------
Reporter: david | Owner: david
Type: enhancement | Status: closed
Priority: normal | Milestone: 1.0.4
Component: request | Version: 1.0.3
Severity: normal | Resolution: fixed
Keywords: | Has_patch: 0
-------------------------+--------------------------------------------------
Comment(by david):
Sample web.config for running on Windows Azure (needs to be in the root of
your {{{Project_WebRole}}} folder), rewriting to the
{{{pub/}}} subdirectory which cannot be made document root on Azure:
{{{
#!xml
<configuration>
<system.webServer>
<!-- DO NOT REMOVE: PHP FastCGI Module Handler -->
<handlers>
<clear/>
<add name="PHP via FastCGI" path="*.php" verb="*"
modules="FastCgiModule" scriptProcessor="%RoleRoot%\approot\php\php-
cgi.exe" resourceType="Unspecified"/>
<add name="StaticFile" path="*" verb="*"
modules="StaticFileModule,DefaultDocumentModule,DirectoryListingModule"
resourceType="Either" requireAccess="Read"/>
</handlers>
<!-- Example WebRole IIS 7 Configuration -->
<defaultDocument>
<files>
<clear/>
<add value="index.php"/>
</files>
</defaultDocument>
<rewrite>
<rules>
<rule name="pub/ access only">
<match url="(.*)"/>
<action type="Rewrite"
url="/pub/{R:1}"/>
</rule>
<rule name="Agavi Dispatcher for /"
stopProcessing="true">
<match url="^/pub/$"/>
<action type="Rewrite"
url="/pub/index.php?/"/>
</rule>
<rule name="Agavi Dispatcher"
stopProcessing="true">
<match url="^/pub/(.*)$"/>
<conditions
logicalGrouping="MatchAll">
<add
input="{REQUEST_FILENAME}" matchType="IsFile" negate="true"/>
<add
input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true"/>
</conditions>
<action type="Rewrite"
url="/pub/index.php?/{R:1}"/>
</rule>
</rules>
</rewrite>
</system.webServer>
</configuration>
}}}
--
Ticket URL: <http://trac.agavi.org/ticket/1265#comment:6>
Agavi <http://www.agavi.org/>
An MVC Framework for PHP5
_______________________________________________
Agavi Tickets Mailing List
[email protected]
http://lists.agavi.org/mailman/listinfo/tickets