Install on Azure websites issues

Hello,



I installed Mautic on an Azure website ( http://azure.microsoft.com/ ) and received a 500 error.

I think that the cause is: IIS was not able to access the web.config file needed for the Web site.



Detailed Error Information:

Module FastCgiModule

Notification ExecuteRequestHandler

Handler PHP54_via_FastCGI

Error Code 0x00000000

Requested URL http://mywebsite:80/index.php/

Physical Path D:homesitewwwrootindex.php

Logon Method Anonymous

Logon User Anonymous



Please create a web.config that can do the UrlRewrite and other stuff from .HTACCESS.



In the following link are some detail to document the issue:

Paragraph: .HTACCESS VS. WEB.CONFIG URL REWRITE

http://www.hanselman.com/blog/InstallingSendyAPHPAppOnWindowsAzureToSendInexpensiveNewsletterEmailViaAmazonSES.aspx



On another hand, Mautic was tested with Azure SQL?



Thank you in advance.

Gabriel

Hello,

I installed Mautic on an Azure website ( http://azure.microsoft.com/ ) and received a 500 error.
I think that the cause is: IIS was not able to access the web.config file needed for the Web site.

Detailed Error Information:
Module FastCgiModule
Notification ExecuteRequestHandler
Handler PHP54_via_FastCGI
Error Code 0x00000000
Requested URL http://mywebsite:80/index.php/
Physical Path D:homesitewwwrootindex.php
Logon Method Anonymous
Logon User Anonymous

Please create a web.config that can do the UrlRewrite and other stuff from .HTACCESS.

In the following link are some detail to document the issue:
Paragraph: .HTACCESS VS. WEB.CONFIG URL REWRITE
http://www.hanselman.com/blog/InstallingSendyAPHPAppOnWindowsAzureToSendInexpensiveNewsletterEmailViaAmazonSES.aspx

On another hand, Mautic was tested with Azure SQL?

Thank you in advance.
Gabriel

Any update? :slight_smile:

As far as I know we haven’t tested Mautic on Azure. Its worth trying but no has done it yet. There are drivers for MSSql which I suppose in theory that should work just fine. I might try playing around with it, but the web.config file is definitely not included with Mautic so if that’s needed to make URL rewrites work that’ll have to be sorted out by someone who knows the Azure environment.

Alright

Even though I said that this hasn’t been attempted I couldn’t leave well enough alone and had to go ahead and try to make it work!

So, my biggest obstacles so far have been:

  1. How in the world do you set up something like composer to run on Azure? I see some links about command line SDK which I installed, but working in a world where I can’t simply do php composer.phar is a really sad place. Have you figured out how to best get Mautic and all the vendor libraries running?

  2. What kind of Azure set up do you have running? I went and created a ‘custom web app’ as recommended by Symfony:

http://symfony.com/doc/current/cookbook/deployment/azure-website.html

Any advice you can give me so that as I try this I can get over the early azure hurdles?

First of all, thank you Chad for your involvement.

Also, i want to say that I am not a PHP dev.

  1. I have installed Mautic using the .zip file from https://www.mautic.org/download . This file contain complete instalation. You can upload the files on the Azure server in several modes:
  • upload using ftp the .zip on server and unzip using the Kudu service console
  • upload the unziped files directly on server
  • unzip the .zip in a local folder and publish on the server using WebMatrix ( a dev tool; can sync files from local folder with the files from server).

The Kudu console can be found at:
https://[your-website-name].scm.azurewebsites.net
after you created the application.

As you can see, i have not used the composer and git deployment.

  1. Web app creation:
    Yes, is ok the “custom web app”.
    You have following options:

For the website:
a. you can use 10 free websites, with some limitations
b. as long as you are in trial period, you can setup more powerfull versions ( shared, basic or standard)
In this way you can have an account for testing Mautic in the future for free.

For the database:
a. you can use Azure SQL ( this is a MSSQL with almost all features and with many benefits as a cloud service) - free for trial period
b. you can use a MySQL database provided by a 3rd party - ClearDB ( a 20 mb database is free)
c. you can setup a VM for a MySQL server ( using any OS ) and create a database from there. In this case you lose the advantages of the cloud concept ( automatic backup, updates, … ).

As far as i see that Mautic supports also IIS + MSSQL ( https://www.mautic.org/download/requirements ), you can use as database Azure SQL or MySql.

In my Mautic instalation i use Azure SQL, but beacause i have not passed the install process, i can’t tell if there are some issues with the database use.

As far i understand, is needed to meke these steps ( also as in http://symfony.com/doc/current/cookbook/deployment/azure-website.html ):

  1. Create Web Site
    2: Create new MySQL or AzureSQL Database - // using AzureSQL has some major benefits in production in Azure context setup
  2. Configuring the Azure Website for Symfony - from control panel + Kudu
  • latest PHP Runtime
  • php.ini Configuration Settings
  • Enabling the PHP intl Extension // or other extension needed and not activated
  1. Upload files on server using FTP ( with complete dependencies done before uploading ) // as i posted above, in the root of the website
    or
    4’. Upload files using git + composer, as in symfony.com tutorial
  2. Configure the Web Server // create the web.config as in:
    http://symfony.com/doc/current/cookbook/deployment/azure-website.html
    And
    Paragraph: .HTACCESS VS. WEB.CONFIG URL REWRITE from http://www.hanselman.com/blog/InstallingSendyAPHPAppOnWindowsAzureToSendInexpensiveNewsletterEmailViaAmazonSES.aspx

As a final word, i think that you will find usefull:
From control panel:
WebApp > [yourwebapp name] > Configure>
Activate: Application Diagnostics and Site Diagnostics ( use the file system to store the logs)
Then you can connect using FTP in order to read these files.

If you need any other information, please ask me.

Regards,
Gabriel

Chad , is there any progress in this issue?

Regards,
Gabriel

Hi Gabriel

Sorry I haven’t had a chance to get back to this yet after my first attempt. I’ll try again this weekend!

Hi Chad,

If you think necessary, we can discuss online when you working on this issue. In this case, send me an email. Regarding time zone: I live in Europe.

Regards,
Gabriel

Any update?

Hi, I managed to make it work on Azure Websites, if you have any question I can help.

Thank you, @oriolqc ! I suggest you to write a step-by-step short guide, as i saw also your post related to "IIS Rewrite rules ". Maybe there are more people interested in this matter. I will try to install Mautic in the next days.

Done! Find it here: https://www.mautic.org/community/index.php/2667-installing-mautic-on-azure-websites

Great! Thank you @oriolqc !