Copied to clipboard

Flag this post as spam?

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


  • Scott 8 posts 109 karma points
    Jun 26, 2017 @ 14:04
    Scott
    0

    Error with Scheduled Publishing on a Azure WebApp

    Hi Everyone, I've got a Umbraco sire (7.5.3) on a Azure WebApp that keeps giving me this error, I've had a look around but can't seem to find a way to fix it.

    I've activated Web Sockets in my app etc... but this hasn't helped.

    This is the error:

    2017-06-26 12:07:49,479 [P3448/D2/T87] ERROR Umbraco.Web.Scheduling.ScheduledPublishing - Failed (at "http://localhost:80/umbraco"). System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: Unable to connect to the remote server ---> System.Net.Sockets.SocketException: An attempt was made to access a socket in a way forbidden by its access permissions 127.0.0.1:80 at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult) at System.Net.ServicePoint.ConnectSocketInternal(Boolean connectFailure, Socket s4, Socket s6, Socket& socket, IPAddress& address, ConnectSocketState state, IAsyncResult asyncResult, Exception& exception) --- End of inner exception stack trace --- at System.Net.HttpWebRequest.EndGetRequestStream(IAsyncResult asyncResult, TransportContext& context) at System.Net.Http.HttpClientHandler.GetRequestStreamCallback(IAsyncResult ar) --- End of inner exception stack trace --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Umbraco.Web.Scheduling.ScheduledPublishing.

    Thanks

  • Marc Goodson 2141 posts 14324 karma points MVP 8x c-trib
    Jun 26, 2017 @ 17:38
    Marc Goodson
    0

    Hi Scott

    In your /config/umbracosettings.config file have you got an UmbracoApplicationUrl set? (it's write at the bottom of config file as an attribute on the routing element)

    perhaps to http://localhost:80 ?

    if so then your webapp, is using that as the baseurl for scheduled publishing...

    regards

    Marc

  • Scott 8 posts 109 karma points
    Jun 27, 2017 @ 09:13
    Scott
    0

    Hi Marc,

    Thanks for your reply.

    I've checked the UmbracoApplicationUrl and it's set to "".

    shall I try changing it to my live domain?

    Thanks

  • Marc Goodson 2141 posts 14324 karma points MVP 8x c-trib
    Jun 27, 2017 @ 16:28
    Marc Goodson
    100

    Hi Scott

    yes, setting up scheduled publishing correctly has a lot of hoops to jump through depending on the hosting environment, and a number of configuration factors.

    Essentially Umbraco is making a request to itself to an endpoint every so often to see if there is anything to publish, so if for any reason it can't successfully make that request you get an error like you see above.

    How Umbraco determines the Url depends on whether your are load balancing etc, but first it will look for this umbracoApplicationUrl setting, if it's blank it will look for a 'baseUrl' setting on the scheduledTasks options in the same umbracoSettings config file, and if this is not set, it looks at the list of distributedCall Servers in the same config file and if nothing is set, the first request Umbraco receives is used as this Url!

    If you are running the site over https, then the umbracoApplicationUrl needs to include the https bit in the url eg: https:\yoursite.com/umbraco AND umbracoUseSSL must be set to true in the web.config appsettings.

    So yes set the umbracoApplicationUrl to be your site and see if that makes the errors disappear!

    Other reasons why the request might fail include 'url rewriting' of all requests to the /umbraco folder that some people put in place for security purposes - or problems with DNS eg the server doesn't have access to a DNS server to be able to make a request to itself.

    regards

    Marc

  • Scott 8 posts 109 karma points
    Jul 05, 2017 @ 10:41
    Scott
    0

    Hi Marc,

    Sorry about the late reply.

    Thanks for your help, I've changed the umbracoApplicationUrl to the site. I'll let you know if it works.

    Thanks

  • Niklas Ederoth 4 posts 74 karma points
    Aug 18, 2017 @ 07:31
    Niklas Ederoth
    0

    Hi Scott, Did this change work for you?

    /Nick

Please Sign in or register to post replies

Write your reply to:

Draft