IIS anti generation Cloudreve trampling record

What is Cloudrestore

It is a network disk program. For specific introduction and help, see file
Why is there this article? Although some users use Windows servers, they don't seem to use IIS, so I'll talk about the holes I stepped on and leave a file for myself. This article has been updated to the official document page.

premise

You have run Cloudrestore according to the documentation, that is, you can access the port set by localhost: with your browser to see the network disk interface. Advance here MySQL is recommended for the database Don't try to save time by using SQLite. There are many problems.

You have installed IIS and added a website, which can be accessed through the Internet; IIS has also been installed URL Rewrite and ARR modular.

Enable ARR

Open IIS and enter the Application Request Routing Cache , and then enter the right Server Proxy Settings... , check the top Enable proxy , and uncheck the following Reverse rewrite host in response headers Click Apply on the right to save the changes.

If you do not uncheck the reverse rewriting host header, the Cloudrestore API will not be able to return the correct address, resulting in failure to preview pictures and videos.

Retain host header

Open IIS and enter the Configuration Editor , go to system.webServer/proxy Node, adjust the following preserveHostHeader by True Then click the application on the right to save the changes. (Microsoft crawls. What kind of operation is it to put some settings into the ARR graphical interface??)

This setting seems to have no impact on Cloudrestore, but IIS reverse generation is used RSSHub It must be opened.

Configure reverse generation rules

This is web.config The contents of the file can be placed in the root directory of the target website. This example includes two rules and one restriction:

  • HTTP to HTTPS redirect (HTTPS is mandatory. You need to configure SSL before using it. If not, please delete the rule)
  • Rerwite (reverse substitution)
  • requestLimits In sixty million It refers to the size limit of the transferred file. The unit is byte. If you want to use the local storage policy, please change the size to the theoretical maximum file size
 <? xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <rewrite> <rules> <rule name="HTTP to HTTPS redirect" stopProcessing="true"> <match url=".*" /> <conditions logicalGrouping="MatchAll" trackAllCaptures="false"> <add input="{HTTPS}" pattern="off" /> </conditions> <action type="Redirect" url="https://{HTTP_HOST}/{R:0}" redirectType="Permanent" /> </rule> <rule name="Rerwite" stopProcessing="true"> <match url=".*" /> <conditions logicalGrouping="MatchAny" trackAllCaptures="false"> <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" /> <add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" /> </conditions> <action type="Rewrite" url=" http://localhost:5212/ {R:0}" /> </rule> </rules> </rewrite> <security> <requestFiltering allowDoubleEscaping="true"> <requestLimits maxAllowedContentLength="60000000" /> </requestFiltering> </security> </system.webServer> </configuration>

Other problems

Failed to initialize donation Alipay
SQLite to MySQL
Please refer to: https://forum.cloudreve.org/d/1460
PHPMyAdmin can be used for operations. Errors may be reported during import. Please resolve the problems according to the errors. At the same time, pay attention to the time zone settings.
give the thumbs-up
  1. Arthur East say:

    Spicy chicken

    1. Wandering the dog's blog late at night, I saw this comment and was hungry.....

      1. Qianshan say:

        have a look

  2. It's really good and powerful

  3. Thanks for sharing like one

  4. wdxxg say:

    Good writing, dogs rush!!!

  5. Thanks for sharing

  6. Four seasons say:

    Bovine

Post reply

E-mail addresses will not be made public. Required items are marked with *