[SOLVED] Pydio Sync Client not working with Pydio

Having issues with your DietPi installation, or, found a bug? Post it here.
MonZon
Posts: 45
Joined: Fri Mar 31, 2017 6:07 pm

Re: [SOLVED] Pydio Sync Client not working with Pydio

Post by MonZon »

Alright, Windows Sync is connecting fine now, but still can't sync files - Unexpected Error: No JSON object could be decoded.
User avatar
MichaIng
Site Admin
Posts: 2423
Joined: Sat Nov 18, 2017 6:21 pm

Re: [SOLVED] Pydio Sync Client not working with Pydio

Post by MichaIng »

Hmm: https://github.com/pydio/pydio-sync/issues/162
https://github.com/pydio/pydio-sync/issues/60

Generally seems to be a json parse (syntax) error: https://stackoverflow.com/questions/148 ... be-decoded

Only json file within pydio_data: /mnt/dietpi_userdata/pydio_data/plugins/boot.conf/bootstrap.json
Much more of them within /var/www/pydio

Ah I think I found it:
/var/www/pydio/plugins/boot.conf/ will currently not be rewritten to non index.php path, since a dot is contained. Perhaps this breaks client access to the contained resources. Needs more complicated rewrite rules... Damn why use dots inside URLs/paths at all with non-static content... :roll:

Okay thanks for feedback, I will try to find a solution. Sadly the Pydio docs do not contain any of this...
User avatar
MichaIng
Site Admin
Posts: 2423
Joined: Sat Nov 18, 2017 6:21 pm

Re: [SOLVED] Pydio Sync Client not working with Pydio

Post by MichaIng »

@MonZon
Okay, old and new guides are highly mixed and required rewrite rules have changed since Pydio 6. They really need to cleanup their docs...

Since there are no other .php files that need to be called directly, the following should (99-dietpi-pydio.conf file) work:

Code: Select all

$HTTP["url"] =~ "^/pydio($|/)" {
        # Deny access to pydio/data dir
        $HTTP["url"] =~ "^/pydio/(data|conf|core)" {
                url.access-deny = ("")
        }

        # Pretty URL rewrite, required for sync clients
        url.rewrite-if-not-file = ( "^/pydio/(.+)/?$" => "/pydio/index.php/$1" )

        # Disable PHP output buffering, recommended by Pydio
        setenv.add-environment += ( "PHP_ADMIN_VALUE" => "output_buffering=Off" )

}
Will also test here, if the dot was really the reason for sync failure.
_____
Tested here with Windows client and works well. The same in your case?
MonZon
Posts: 45
Joined: Fri Mar 31, 2017 6:07 pm

Re: [SOLVED] Pydio Sync Client not working with Pydio

Post by MonZon »

Syncs fine now. Will test more.

Thanks a lot!

P.S. Would you mind checking the Tonido for the same bug? Looks similar to me. Long time ago they mentioned that Arm servers are not compatible with the Windows Sync application, but they have a separate RaspberryPi image on their site now - so there is a slight chance that they fixed it.
User avatar
MichaIng
Site Admin
Posts: 2423
Joined: Sat Nov 18, 2017 6:21 pm

Re: [SOLVED] Pydio Sync Client not working with Pydio

Post by MichaIng »

Could you please open a new issue on GitHub (or here) about this: https://github.com/Fourdee/DietPi/issues
This topic here is too far off topic now ;).

I will have a look after some other things done (also Pydio config for Nginx with same issue :roll:).
MonZon
Posts: 45
Joined: Fri Mar 31, 2017 6:07 pm

Re: [SOLVED] Pydio Sync Client not working with Pydio

Post by MonZon »

It is already mentioned here: https://github.com/Fourdee/DietPi/issue ... -290915782
and here: viewtopic.php?f=15&t=824&start=10

Sorry about the offtopic info here.
User avatar
MichaIng
Site Admin
Posts: 2423
Joined: Sat Nov 18, 2017 6:21 pm

Re: [SOLVED] Pydio Sync Client not working with Pydio

Post by MichaIng »

@MonZon
Could you try if shared public links work?

The sample Nginx config suggest to not deny direct access to /pydio_data/public and I read somewhere that this is used for public shares. However the default .htaccess files (used when Apache is installed) DO block this directory. Only thing I could imagine is that a new .htaccess is created when first public share is created.
But much seems to have changed about required rewrite and access rules the last Pydio versions. All guides suggest different things, so we cannot rely on it but need to first out ourself :cry:.

If indeed public shares do currently not work, please replace (data|conf|core) pattern with:
(\.|conf|core|data/(files|personal|logs|plugins|tmp|cache)|plugins/editor\.zoho/agent/files)

This then matches the sample Nginx config, block again some more, but not /pydio_data/public: https://github.com/pydio/pydio-core/blo ... onf.sample

Actually works fine here without data/public access. Public links are in scheme /pydio/public/38f487, so no /data/ in path. So data/public exclusion from block seems to be a remain from older times, not required anymore.
MonZon
Posts: 45
Joined: Fri Mar 31, 2017 6:07 pm

Re: [SOLVED] Pydio Sync Client not working with Pydio

Post by MonZon »

I've tried to use shared link but from the same LAN - it just shows empty white page, no error, nothing.

What file do I need to edit to replace the mentioned data pattern?
Post Reply