Repository navigation
Description
Hi there,
We have been looking to deploy OwnCloud on our company servers, as a replacement for our existing sync provider, as we don't like the idea of our data being held on third-party servers.
However, there is currently one thing that is blocking us, which is that the default sync settings in the OwnCloud client do not meet the basic sync requirements of file synchronisation, namely there are important files that are excluded from the sync. The specific files that affect us (as a web agency) are .htaccess files, and hidden files in general (though there may be others, as I haven't done an exhaustive check of the list yet).
We have removed .htaccess files from the block list on the server, but it appears that the client is still blocking them.
I am aware that there are settings in the client (or rather, somewhere on the client machine, as you can't remove the .htaccess file exclusion from within the GUI). However, this means that we are dependent on all employees correctly setting these settings on every machine/installation that they use, and hoping they don't get modified when the client is upgraded (as I have read reports of on the forums).
Sync software that doesn't sync everything is, frankly, pointless - in fact, it's downright dangerous if users aren't aware of the exclusions. As a company, we need to be certain that everything we expect to be synced is being synced, always, and not be reliant on individual employees to enforce this.
So enough of the complaining - let's make a constructive suggestion to try and resolve this issue, and turn OwnCloud into a fully enterprise-ready product.
What I would like to see is the ability for the exclusions to be controlled by the server admin, so they can just be set in one place, so the software 'just works', straight out of the box (like most other sync services).
The way I would manage it is by adding a client_config.php file in the config folder, which can be used to set the default client configuration. (The settings could go in config.php but it makes sense for me to separate out the server and client configuration settings.).
Only sync-related settings would be configurable from the server, specifically we would need a sync_hidden_files boolean setting, and an array of ignore_patterns. This latter setting would need to handle the 'can be deleted' flag, so would either be multi-dimensional (with each entry containing two properties, pattern and can_be_deleted) or be split into two arrays, one for each type of exclusion.
It should also provide a way to specify whether the client should allow the user to over-ride these settings (probably on a per-ignore-pattern level).
When the client initiates the sync, it will pull down the server config and then apply whatever additional local config has been specified (respecting the 'can change' settings).
PS - I am well aware of why syncing .htaccess file could be dangerous if you haven't configured your server properly, and that is not relevant to this issue. This issue is about providing appropriate software configuration to support people who are able to secure a server properly and who want their sync software to, well, sync.
Activity
nickvergessen commentedon Feb 24, 2016
You could also change https://github.com/owncloud/client/blob/c46547592c7bcf7d70e37890d82383ce72afb9be/sync-exclude.lst#L22 and compile your own clients.
However, we are blocking
.htaccessfor a reason, e.g. #22412But maybe @LukasReschke can tell more
LukasReschke commentedon Feb 24, 2016
More of a pure client issue, see also owncloud/client#434
MarkMaldaba commentedon Feb 24, 2016
That's a possibility, though I'm not sure it's foolproof. I doubt we could enforce that our employees only installed our custom build, rather than downloading direct from the Owncloud website. Also, what happens when an auto-update is triggered?
I know, hence my post-script. What is needed is a way for the server to indicate that there is no security issue with .htaccess files, and that therefore this file should not be excluded by the client.
MarkMaldaba commentedon Feb 24, 2016
To help the discussion, I have put together a sample
client_config.phpfile:Some notes:
may_be_deletedargument indicates whether the file may be deleted by OwnCloud if the parent folder is deleted (as per the preferences UI). This setting may be omitted, in which case it defaults to false.is_lockedargument indicates whether the client allows the user to edit/remove the item. May be omitted, in which case it defaults to true.sync_hidden_files_lockedindicates whether the client can change the sync hidden files option, and defaults to false if omitted.Points 2 and 3 imply that the client will need to keep track of situations where the client has explicitly deleted/modified a client-supplied pattern, so that changes to the server config are applied correctly (i.e. they don't restore a pattern that the user has deleted). Though, obviously, if the server changes the
is_lockedsetting from false to true then the pattern should re-appear as per the server definition.Not that
may_be_deletedis a confusing name, but it was chosen to match the confusing ignore list UI. I would much rather invert the flag and call itblock_folder_deletion, defaulting to to true, but that might cause issues as it is the inverse of the current implementation.MarkMaldaba commentedon Mar 18, 2016
@RealRancor: I don't think this is quite a duplicate, though they are similar. This is specifically about providing a server-side implementation of the client's ignore list (which is based on filename patterns, as well as having an 'ignore hidden' flag) whereas #19385 is about ignoring specific files in specific folders. The solutions may or may not overlap (wholly or partially), but it is equally possible for either ticket to be resolved without the other being satisfied.
PVince81 commentedon Oct 10, 2016
ref: webdav property to tell the clients "do not sync this": #26311
MarkMaldaba commentedon Oct 30, 2016
I'm not sure whether that's related (it may be, but not wholly).
This ticket is about allowing the default client configuration options to be controlled by the server admin rather than about implementing server side rules.
There may be some overlap - certain configurations may allow the server perform blocking actions - but that is not the main thrust of this ticket.
AnrDaemon commentedon Oct 31, 2016
No, that's not related.
PVince81 commentedon Dec 18, 2017
closing in favor of #7956
lock commentedon Aug 1, 2019
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.