Mailing List Archive

Ubuntu 16 setup
So, I'm doing my first setup...

Ubuntu 16.04

Everything works pretty well except the Apache2 configs.

I setup a config, like this:

<VirtualHost 1.2.3.4>
DocumentRoot /usr/share/davical/htdocs
DirectoryIndex index.php index.html
ServerName davical.example.net
ServerAlias calendar.example.net
Alias /images/ /usr/share/davical/htdocs/images/
<Directory /usr/share/davical/htdocs/>
AllowOverride None
Order allow,deny
Allow from all
</Directory>
AcceptPathInfo On
</VirtualHost>

[.I've actually had a variety of configs, but this is one I tried. All seemed to have the same result.]

Then I enable the site, and restart Apache.
However, when I go to http://1.2.3.4/davical/index.php I get the text of the PHP file, not a server processed PHP output.

I'm sure this is simple, but I haven't stumbled across a fix and I'm getting pretty frustrated.

Any ideas?

TIA

-Greg
Re: Ubuntu 16 setup [ In reply to ]
I see two probable issues:

1. With that virtualhost configuration, your Davical setup is available at calendar.example.net or davical.example.net.

2. If php is not being processed, you probably need to configure Apache to hand files with a php extension over to PHP.

3. In the Davical wiki you'll find more options for the virtualhost configuration, some of which are required to have a fully working setup.

Hth,
Vincent

Verzonden vanaf mijn Sony Xperiaâ„¢-smartphone

---- Gregory Sloop schreef ----

>So, I'm doing my first setup...
>
>Ubuntu 16.04
>
>Everything works pretty well except the Apache2 configs.
>
>I setup a config, like this:
>
><VirtualHost 1.2.3.4>
> DocumentRoot /usr/share/davical/htdocs
> DirectoryIndex index.php index.html
> ServerName davical.example.net
> ServerAlias calendar.example.net
> Alias /images/ /usr/share/davical/htdocs/images/
> <Directory /usr/share/davical/htdocs/>
> AllowOverride None
> Order allow,deny
> Allow from all
> </Directory>
> AcceptPathInfo On
></VirtualHost>
>
>[.I've actually had a variety of configs, but this is one I tried. All seemed to have the same result.]
>
>Then I enable the site, and restart Apache.
>However, when I go to http://1.2.3.4/davical/index.php I get the text of the PHP file, not a server processed PHP output.
>
>I'm sure this is simple, but I haven't stumbled across a fix and I'm getting pretty frustrated.
>
>Any ideas?
>
>TIA
>
>-Greg
>------------------------------------------------------------------------------
>Check out the vibrant tech community on one of the world's most
>engaging tech sites, SlashDot.org! http://sdm.link/slashdot
>_______________________________________________
>Davical-general mailing list
>Davical-general@lists.sourceforge.net
>https://lists.sourceforge.net/lists/listinfo/davical-general
Re: Ubuntu 16 setup [ In reply to ]
If you're getting the text of the php you might want to make sire you've run the following on that server:

sudo apt-get install libapache2-mod-php7.0
a2enmod php7.0

These are of course assuming you want to run php 7 which I think you do unless you have some legacy php apps that don't run with it. Hope this helps
--
Trev Peterson
Advanced Reality
Email: trev@advanced-reality.com
Phone: +1 847 406 9018

On December 3, 2016 3:01:36 PM GMT+08:00, Vincent Van Houtte <vvh@aplusv.be> wrote:
>I see two probable issues:
>
>1. With that virtualhost configuration, your Davical setup is available
>at calendar.example.net or davical.example.net.
>
>2. If php is not being processed, you probably need to configure Apache
>to hand files with a php extension over to PHP.
>
>3. In the Davical wiki you'll find more options for the virtualhost
>configuration, some of which are required to have a fully working
>setup.
>
>Hth,
>Vincent
>
>Verzonden vanaf mijn Sony Xperiaâ„¢-smartphone
>
>---- Gregory Sloop schreef ----
>
>>So, I'm doing my first setup...
>>
>>Ubuntu 16.04
>>
>>Everything works pretty well except the Apache2 configs.
>>
>>I setup a config, like this:
>>
>><VirtualHost 1.2.3.4>
>> DocumentRoot /usr/share/davical/htdocs
>> DirectoryIndex index.php index.html
>> ServerName davical.example.net
>> ServerAlias calendar.example.net
>> Alias /images/ /usr/share/davical/htdocs/images/
>> <Directory /usr/share/davical/htdocs/>
>> AllowOverride None
>> Order allow,deny
>> Allow from all
>> </Directory>
>> AcceptPathInfo On
>></VirtualHost>
>>
>>[.I've actually had a variety of configs, but this is one I tried. All
>seemed to have the same result.]
>>
>>Then I enable the site, and restart Apache.
>>However, when I go to http://1.2.3.4/davical/index.php I get the text
>of the PHP file, not a server processed PHP output.
>>
>>I'm sure this is simple, but I haven't stumbled across a fix and I'm
>getting pretty frustrated.
>>
>>Any ideas?
>>
>>TIA
>>
>>-Greg
>>------------------------------------------------------------------------------
>>Check out the vibrant tech community on one of the world's most
>>engaging tech sites, SlashDot.org! http://sdm.link/slashdot
>>_______________________________________________
>>Davical-general mailing list
>>Davical-general@lists.sourceforge.net
>>https://lists.sourceforge.net/lists/listinfo/davical-general
>
>
>------------------------------------------------------------------------
>
>------------------------------------------------------------------------------
>Check out the vibrant tech community on one of the world's most
>engaging tech sites, SlashDot.org! http://sdm.link/slashdot
>
>------------------------------------------------------------------------
>
>_______________________________________________
>Davical-general mailing list
>Davical-general@lists.sourceforge.net
>https://lists.sourceforge.net/lists/listinfo/davical-general


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Davical-general mailing list
Davical-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/davical-general
Re: Ubuntu 16 setup [ In reply to ]
TP> If you're getting the text of the php you might want to make sire
TP> you've run the following on that server:

TP> sudo apt-get install libapache2-mod-php7.0
TP> a2enmod php7.0

TP> These are of course assuming you want to run php 7 which I think
TP> you do unless you have some legacy php apps that don't run with it. Hope this helps

That was it. I would have though the Ubuntu package would have installed and enabled PHP as it's a requirement of the package you're installing. [.And it was a clean install - with nothing other than the basic Ubuntu 16.04 server install otherwise, so I can't see a reason PHP would have been left alone as to not conflict with another PHP instance.]

I probably should have twigged to the fact that the PHP code wasn't being executed - but I was frustrated and didn't end up down that trail.

Thanks!
-Greg