-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
spksrc: Fully use DSM7 var directory #5163
Conversation
I tried to review, since I know you put a lot of work in it, but I am not fully understanding (even after reading the previous PR) what this change will do? |
Thnx @Safihre for looking into it. It is now ready for review (you where a few minutes to early). I've added a much better description + a diagram that explains it hopefully well. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Based on your diagram, it looks good. All changes seem logical.
But @hgy59 or someone else is more an expert.
@SynoCommunity/developers Friendly reminder for reviews. Unless there is opposition to this PR I'll look into merging in the coming days. |
I have a package under development (urbackup) where the cross packages create config files in the var folder. PLIST contains entries like After rebase to include this PR, DSM 7 packages cannot be created anymore.
@th0ma7 any idea how to handle this? |
@hgy59 can you point me to your development branch i'll look into it probably tomorrow. |
- fix "Copy and merge var and target/var to $(STAGING_DIR)/var"
@th0ma7 the copy and merge of different var folders needs two command lines, as tar must be executed within each var folder separately. |
- rework fix "Copy and merge var and target/var to $(STAGING_DIR)/var"
The following existing cross packages have var folders in PLIST
@th0ma7 shall I create a dedicated PR to merge this fix to master? |
Yes please do @hgy59 , I'll have a second look at it as well. EDIT: I can't reproduce your issue... I tried with rsnapshot and mutt and all is good with the current code. |
- avoid .. in INSTALL_PREFIX_VAR
- use resource worker to create shared folder - adjust wizards for shared folder creation - create readme.html that can be opened in the browser - create dummy file as for DSM7 we cannot create packages without content (since SynoCommunity#5163: Fully use DSM7 var directory)
Description
Motivation: Follow-up to to both #4579 and #4797 with focus only on
var
. This now uses previously merged PR such as:target/var
tovar
inspksrc.service.installer.dsm7
.new
suffix new files when previous ones already exist. User can then refer to them and adapt their own configuration as needed.Current framework simply move files from
target/var
totarget/../var
at package installation/upgrade time. While it's probably fine for most use-cases, this doesn't adapt all configuration files at build time using the "real" end-state path and most importantly the application isn't "aware" by default of the expectedvar
directory path.Solving this require using
localstatedir
option at configuration time. Doing so enforces the application to have an awareness and use by default the new DSM7var
directory and thus, installs files at the proper location and adjust paths in configurations at build time. Not doing so leaves a bit of unknown on actual application state & behavior.This PR aims at solving the current limitations by doing the following on top of rsync work (#4997):
localstatedir
for DSM7 builds. At package generation time, files installed under<workdir>/install/var/package/<package>/var
are now being handled in order to be packaged and installed properly.Details
This new implementation is a major step above previous attempt as it:
etc
in a later workChecklist
all-supported
completed successfullyType of change