Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Steve Borg 28 posts 99 karma points
    May 31, 2016 @ 16:43
    Steve Borg
    0

    Flexible Load Balancing - preventing access to back-office from load balanced servers

    Hi,

    The flexible load balancing document states:

    "You will designate a single server to be the back-office server for which your editors will log into for editing content. Umbraco will not work correctly if the back-office is behind the load balancer."

    I have traversed the documents and come to the conclusion that there is no need to set the server names in the servers section of any of the umbracoSettings.config files when using flexible load balancing. Firstly, is this correct?

    So, if I am using the Option #2 : File Storage with File Replication approach where I have one back-office server: 'a.com' and two front-end servers behind a load balancer: 'b.com', what is to stop a person accessing the back-office via the url: b.com/umbraco?

    Is it correct just to set up a rewrite rule so that b.com/umbraco goes to a.com/umbraco or should this be done in a different way?

    Thank you.

  • Dave Woestenborghs 3504 posts 12134 karma points MVP 9x admin c-trib
    Jun 01, 2016 @ 08:36
    Dave Woestenborghs
    0

    Hi Steve,

    have traversed the documents and come to the conclusion that there is no need to set the server names in the servers section of any of the umbracoSettings.config files when using flexible load balancing. Firstly, is this correct?

    This is correct

    So, if I am using the Option #2 : File Storage with File Replication approach where I have one back-office server: 'a.com' and two front-end servers behind a load balancer: 'b.com', what is to stop a person accessing the back-office via the url: b.com/umbraco?

    Is it correct just to set up a rewrite rule so that b.com/umbraco goes to a.com/umbraco or should this be done in a different way?

    You can do this by adding a rewrite url in your web.config

     <rule name="Backoffice access" enabled="true">
              <match url="^umbraco(#/)?(#)?(.*)"/>
              <conditions logicalGrouping="MatchAll">
                <add input="{R:0}" pattern="^umbraco/masterpages/?" ignoreCase="true" negate="true"/>
                <add input="{R:0}" pattern="^umbraco/RestServices/?" ignoreCase="true" negate="true"/>
                <add input="{R:0}" pattern="^umbraco/webservices/?" ignoreCase="true" negate="true"/>
                <add input="{R:0}" pattern="^umbraco/Surface/?" ignoreCase="true" negate="true"/>
                <add input="{R:0}" pattern="^umbraco/api/?" ignoreCase="true" negate="true"/>
                <add input="{R:0}" pattern="^umbraco/ping.aspx" ignoreCase="true" negate="true"/>
                <add input="{HTTP_HOST}" pattern="^(a.com)$" ignoreCase="true" negate="true"/>
              </conditions>
              <action type="Redirect" url="http://{HTTP_HOST}/"/>
            </rule>
    

    This rewrite will restrict backoffice access, so it is only available on server a.com.

    Dave

  • Steve Borg 28 posts 99 karma points
    Jun 09, 2016 @ 16:41
    Steve Borg
    0

    Hi Dave,

    Many thanks for the reply and especially for including the rewrite rules (I had forgotten about umbraco/api etc.)

    We just went live with the load balanced system and seems to be behaving well.

    Thank you,

    Best regards,

    Steve

Please Sign in or register to post replies

Write your reply to:

Draft