scubajeff / pico_lespas

Pico CMS theme for Nextcloud photo app Les Pas
Apache License 2.0
5 stars 1 forks source link

Troubles with blogging in apache2 #5

Open rusangl opened 3 months ago

rusangl commented 3 months ago

I would like to renew this issue: https://github.com/scubajeff/pico_lespas/issues/2 Several month ago I got some time for experiments and changed my ncp default apache2 web server to nginx. And since then blogging in Les Pas has been working like a charm without any issues. Recently I helped my friend to install Nextcloud on minipc. For some reasons I chose All-in-One version of Nextcloud to install. But AIO goes again with apache2 in docker. And I faced the same issue, when Les Pas, copying files to Les pas folder and creating .__picoblog__ site can't create any content inside the .__picoblog__ Unfortunately I didn't realize yet how to get the apache2 logs inside docker container, sorry. Is it possible to ask you to check Les Pas behavior with Apache2 please?

scubajeff commented 3 months ago

What's the version of Nextcloud AIO? The highest version of Nextcloud that picocms officially supports is 25.

rusangl commented 3 months ago

The issue seems to be not related with Pico CMS.

For the moment I have 2 instances: 1) barebone Nextcloud (NC 28, nginx, based on raspberrypi 4), 2) AIO (NC 28, apache2, based on x64 minipc). Also I have experience with 3) NextcloudPi (NC 27, default apache2 and manually installed nginx, based on raspberrypi 4)

So Pico CMS itself does its job on all 3 instances in spite of NC25 requirement.

And on instance 1 I have no troubles with Les Pas blogging feature at all.

On Instance 3 with default apache2 web server I could see MKCOL method not allowed error (https://github.com/scubajeff/pico_lespas/issues/2) When I disabled apache2 and installed nginx the issue has gone and I could use Les Pas blogging feature without any troubles.

On instance 2 Pico CMS does its job too if to configure it manually. But not with Les Pas.

My actions: 1) After installing Les Pas on my phone I pointed to NC Lespas folder. It was OK. 2) I created album - it was OK, photos appeared on the instance in Lespas folder after syncronizing. 3) I pressed "manage blog" - Les Pas showed me OK, suggested to copy link to the site. But under this link the site was absent. 4) After that I checked instance 2. I found in the user's pico settings that the site in Lespas/.__picoblog__ folder was created. 5) I went to this folder through ssh. There were no files in assets subfolder and only index.md in content subfolder. 6) I added assets and .md files manually according to the example from instance 1 and the site appeared as expected.

So I assume that the issue is in the interacting of Les Pas and Apache2 (at least version 2.4). Maybe Apache2 needs additional configuration or one of its modules causes the error with MKCOL.

scubajeff commented 3 months ago

Thank you very much for the detail. My own Nextcloud server has stuck with version 25 for a very long time. It's a total relieve knowing that pico actually works with higher version of Nextcloud.

I'm now in the middle of moving to a new house. Hopefully will start debugging again next month.

rusangl commented 3 months ago

Thank you for the response. It is great to hear that Les Pas is still maintained.

As for Pico CMS, the problems in Nextcloud 26+ come only on admin's pico settings page, where you can't install custom themes or plugins. But this repairs it: https://github.com/nextcloud/cms_pico/issues/237#issuecomment-1790870532 Unfrotunately, with every higher Nextcloud version we get more and more bugs and troubles.

And I would like to ask you to implement to the standart theme changes proposed in pull requests, which add lightbox and makes the albums viewing much more comfortable.

Also I managed to write a plugin for pico which allows to use php digest auth for the whole site or single album password protection. It would be nice somehow to implement login/password setting in Les Pas. But it is another story, as I am not a programmer.

scubajeff commented 3 months ago

I was occupied recently by my kids in school, my parents in hospital and the moving to a new house. Not much effort had been spent on pico integration. Things will change in the coming months.

scubajeff commented 1 month ago

In file /etc/apache2/mods-enabled/autoindex.conf, the default setting of Apache include .??* for IndexIgnore, which will reject file operations in hidden folder like .__picoblog__.

If that's the case, you should include line Options -Indexes in your Nextcloud's .htaccess file

BTW, thank you very much for the enlightenment, now my Nextcloud server is running on v28.