Copied to clipboard

Flag this post as spam?

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


  • Martin 7 posts 89 karma points
    Aug 27, 2019 @ 10:39
    Martin
    0

    Access backoffice on subdomain

    Hi

    I would like to only expose "site/umbraco", i.e. backoffice, on a specific subdomain, e.g., "admin.site".

    Suggestions are:

    1. to change "" and related folder names etc.
    2. IIS rewrite (How to prevent access to default backoffice URL)

    Ad 1: This suggestion seems too manual to handle

    Ad 2: Seems straight forward...

    Before I continue with option 2 I would like to hear about experiences, best practices, and so forth - maybe there is an Umbraco configuration to handle it?!

    Thanks

  • Shaishav Karnani from digitallymedia.com 354 posts 1638 karma points
    Aug 27, 2019 @ 12:57
    Shaishav Karnani from digitallymedia.com
    100

    Hi Martin,

    Option 2 is good.

    This is a good article that describes the process. https://www.digbyswift.com/blog/2015/02/changing-umbracos-backoffice-address/

    Regards,

    Shaishav

  • Martin 7 posts 89 karma points
    Aug 27, 2019 @ 14:14
    Martin
    0

    Hi Shaishav

    Thank you! I'm having some problems getting the rewrite to work but it's good to know I'm on the right path.

    The example given has the following:

    <rule name="Restrict umbraco access" stopProcessing="true">
          <match url="^umbraco/?.*"/>
          <action type="CustomResponse" statusCode="404" />
          <conditions>
            <add input="{HTTP_HOST}" pattern="^sub.domain.co/$"/>
            <!--<add input="{REQUEST_URI}" pattern="^umbraco/Surface/.*" negate="true" ignoreCase="true" />-->
            <add input="{REQUEST_URI}" pattern="^umbraco/Surface/.*" negate="true" ignoreCase="true" />
          </conditions>
        </rule>
    

    Leaving as is I get access to login on 'sub.domain.co/umbraco', which redirects me to 'sub.domain.co/umbraco#/content' (if i'm logged in).

    I tried removing the 'Surface/' but that doesn't work.

    I'm publishing, flushing, reseting, and doing anything else I can think of would hinder it working.

    Any ideas?!

    Regards, Martin

  • Martin 7 posts 89 karma points
    Sep 02, 2019 @ 18:34
    Martin
    1

    I figured it out! I had overlooked the umbraco/Surface as the default path for calling Surface controllers. Works like a charm! Thank you!

Please Sign in or register to post replies

Write your reply to:

Draft