Enable plugins on v1.2.18

Hi,

I’m running kanboard as a docker container on photon OS.
I always get the message that my installation is not configured for plugins.

I’ve checked that PHP has zip enabled (which is no surprise as it comes with the container).

I’ve checked that the directory is writable:
drwxr-xr-x 1 root root 4096 Mar 4 15:22 .
drwxr-xr-x 1 root root 4096 Dec 29 00:15 …
-rw-r–r-- 1 root root 1090 Dec 29 00:15 LICENSEdd
drwxr-xr-x 31 root root 4096 Dec 29 00:15 app
drwxr-xr-x 6 root root 4096 Dec 29 00:15 assets
-rwxr-xr-x 1 root root 406 Dec 29 00:15 cli
-rw-r–r-- 1 root root 9520 Dec 29 00:15 config.default.php
-rw-r–r-- 1 root root 278 Mar 4 15:13 config.php
drwxr-xr-x 2 nginx nginx 4096 Mar 4 15:24 data
-rw-r–r-- 1 root root 13094 Dec 29 00:15 favicon.ico
-rw-r–r-- 1 root root 263 Dec 29 00:15 index.php
-rw-r–r-- 1 root root 78 Dec 29 00:15 jsonrpc.php
drwxr-xr-x 9 root root 4096 Dec 29 00:15 libs
drwxr-xr-x 2 nginx nginx 4096 Dec 29 00:15 plugins
-rw-r–r-- 1 root root 25 Dec 29 00:15 robots.txt
drwxr-xr-x 11 root root 4096 Dec 29 00:15 vendor

And this is my config.php:
<?php

defined('ENABLE_URL_REWRITE') or define('ENABLE_URL_REWRITE', true);
defined('LOG_DRIVER') or define('LOG_DRIVER', 'system');

define('PLUGINS_DIR', DIR.DIRECTORY_SEPARATOR.'plugins');
define('PLUGIN_INSTALLER', true);
define('PLUGIN_API_URL', 'https://kanboard.org/plugins.json');

Still no joy. What am I doing wrong? Thanks.

Now I am utterly confused.
I went into app/Core/Plugin/Installer.php and tried to find out which condition failed.
To my astonishment no matter what I did I get the message that my installation has not enabled plugins. So I set it to ‘true’ and I STILL get the same fault message.

??? what is going on here?

class Installer extends \Kanboard\Core\Base
{                                          
    /**                                    
     * Return true if Kanboard is configured to install plugins
     *                                                         
     * @static                                                 
     * @access public                                          
     * @return bool                                            
     */                                                        
    public static function isConfigured()                      
    {                                    
        /**return PLUGIN_INSTALLER && is_writable(PLUGINS_DIR) && extension_loaded('zip');**/
        return true;                                                                         
    }

well, first thing is first. using the docker image, php is cached. so, if you havent restarted the container, doesn’t matter what code you’ve changed, and that includes your config.

the second thing to check, would be your data folder. if you have a config.php in there, it trumps the one in your app folder. that’s important if you are using a previous volume or mounted drive.

1 Like

Thank you! Restarting the container did it.
I wasn’t aware I had to. I hope some other poor soul finds your answer, too. :wink: