Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Plugins Directory Permissions Notification Persists after Fixing #12934

Open
ProCycleDev opened this issue May 18, 2018 · 3 comments
Open

Plugins Directory Permissions Notification Persists after Fixing #12934

ProCycleDev opened this issue May 18, 2018 · 3 comments
Labels
Bug For errors / faults / flaws / inconsistencies etc. Help wanted Beginner friendly issues or issues where we'd highly appreciate community's help and involvement.

Comments

@ProCycleDev
Copy link

ProCycleDev commented May 18, 2018

Server: Ubuntu 16.04 running Nginx 10.3.3
Matomo version: 3.5.0
MySQL version: 10.2.14-MariaDB-10.2.14+maria~xenial-log
PHP version: 7.0.30-0ubuntu0.16.04.1

This error was encountered on a brand new install. The error only appeared after attempting to install a plugin. It was not present before that.

2018-05-18 12_34_47-procycle us - friday may 18 2018 - web analytics reports - matomo

Originally I had perms set so the plugins directory was read only by the webserver

chown -R manager:www-data web/
chmod -R u=rwX,g=rX,o= web/
chmod -R ug=rwX,o= web/tmp
chmod -R ug=rwX,o= web/config
chmod -R ug=rwX,o= web/piwik.js

After trying to install a plugin I got this error, so I fixed the permissions.

chown -R www-data:www-data web/
chmod ug=rwX,o= web/
chmod -R ug=rwX,o= web/plugins

The error message still popped up.

I set 777 for the entire web directory to test and still the error message shows.

2018-05-18 12_40_43-matomoadmin procycleus-matomo_ _srv_www_usage procycle us_web

So I installed the plugin I was trying to install before and it installs perfectly fine. The error message still shows.

I cannot get rid of the error message and I don't know why.

@robertgarrigos
Copy link

I just found myself with this problem. The error disappears once you log out and log in again. But indeed it shouldn't persist for the session.

@NathanQ
Copy link

NathanQ commented Aug 23, 2019

Where are the permissions documented? Thanks.

@tsteur
Copy link
Member

tsteur commented Aug 26, 2019

cheers @robertgarrigos I had a look in the code and noticed it is setting the persistent notification here: https://github.com/matomo-org/matomo/blob/3.12.0-b2/plugins/Marketplace/Controller.php#L435

It is doing this because there's a redirect afterwards. I reckon it should indeed cancel all notifications once it was shown if we are not in an AJAX request 👍

We simply need to add another method cancelAll() and call removeNotification for all notifications. We would need to see though how to detect ajax requests vs regular request. I reckon there's a header set.

@tsteur tsteur changed the title Plugins Directory Permissions Error Warning Persists after Fixing Plugins Directory Permissions Notification Persists after Fixing Aug 26, 2019
@tsteur tsteur added this to the Backlog (Help wanted) milestone Aug 26, 2019
@tsteur tsteur added Bug For errors / faults / flaws / inconsistencies etc. Help wanted Beginner friendly issues or issues where we'd highly appreciate community's help and involvement. labels Aug 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. Help wanted Beginner friendly issues or issues where we'd highly appreciate community's help and involvement.
Projects
None yet
Development

No branches or pull requests

4 participants