-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Linux auto-update #1138
Comments
Planned. There are a lot of more important issues. |
Also check AppImageUpdate for binary delta updates (= users only download a few MB rather than the whole thing each time). |
Do we an ETA for this ? |
Probably this week (issues processed by user donations/requests/votes :)). But cannot promise anything. |
Do you need help with this? Is there any plan or work in progress? I could help, but I don't want to duplicate work by not taking into account anything you may have already done. |
+1 on the above, I'd be happy to help. |
How can we help ? What is the plan ? |
me too |
Happy to help as well 👷 |
Since there seems to be high demand for AppImage updates, I'd like to offer my help too. Update information that is needed for binary delta updates is described in the spec at Of course this could be implemented from scratch, but the easier route would probably be to just use Since @develar wants to allow macOS and Windows users to generate Linux AppImages, a good first step would be to get Volunteers, anyone? Again, happy to help (but I don't run macOS or Windows at the moment). If you have questions, AppImage developers are on #AppImage on irc.freenode.net. |
By the way, if you are wondering what I mean by "binary delta updates", you can see it in action in this video: |
Next week differential updates will be finished for NSIS and I will be free from obligations. So, I will do support auto updates for Linux, as all you waiting it for a long time. |
To make clear — AppImage is awesome. It is not archaic delta updates as Squirrel.Windows support. No, no. It saves hours and hours of developer time (yes, I am tired to answer to WTF, what remote releases I should use?). It is differential update. As Appx format in the Windows Store. It saves bytes for developer because no need to download old release to build block map for a new release. It is very important for CI servers (no previous cache). It saves bytes for client, because block map for one release is fully applicable for any release. Full update will be never downloaded again. It saves developer time — nothing is added to existing workflow. Nothing to test. Nothing to deploy. Yes — Google uses delta updates for Chrome. But what is good for a big company is not always good for a generic use case and often doesn't work. You want to develop your app, not to be release engineer. That's why Microsoft uses differential updates instead of delta for Windows Store. So, stay tuned. Differential update for Windows will be in one week, for Linux — September. |
Didn't know that differential updates for UWP apps existed, but zsync (what powers AppImageUpdate) has been around forever and has been put to good use e.g., for Ubuntu ISOs for a long time. |
@probonopd if I understand correctly, zsync builds blockmap for the whole zip file. Not for files in zip. As appx or our nsis does. |
In the case of AppImage, it would build it for the whole AppImage = ISO9660 or squashfs file. |
99% that auto-update for Linux will use official AppImage solution, but not NSIS like solution. Yes — it will be cool to use LZMA instead of ZIP for AppImage to reduce size (~50%, "30-70%"), but there is a key difference — Linux kernel natively and transparently supports ZIP and so, AppImage zip is not just an intermediate container to unpack (as for And we don't use zsync for NSIS, not only because lack of zsyncmake (https://github.com/salesforce/zsync4j — so, we can port it to node), but because AppX solution, I think, works better (we should operate by file, not the whole packed ZIP with lzma compression). Of course, AppX solution is just a variant of zsync idea (and our client will looks like as zsync client, but modify file not in the local file system, but file in the zip fs). |
You may be interested to hear that @teras has successfully built |
Status: Delta updates for Windows is ready to use (https://github.com/electron-userland/electron-builder/releases/tag/v19.28.4). But after my vacation (21 September) I will fix another issue (because donated and so, has higher priority) and finally will implement auto-updates for Linux. |
I am going to use NSIS implementation of differential update instead of AppImage.
Problem for now, is that NSIS currently uses static slicing, instead of dynamic sized chunks based on hashed content (content defined chunking). It works ok if blockmap computed per-file, but not good in case of AppImage, where zsync applied to whole AppImage file. In any case I need to fix it for NSIS (because of huge Electron executable (80 MB, changed dramatically after code sign)). Decision is not final, depends on experiment results (how good is our differential updating compared to zsync). Great news is that this feature received donation, and so, I will work on it exclusively :) |
@develar Great to hear you're going full-throttle on this! I don't know enough about the technology involved to weigh in but I'm sure you'll make the right decisions! Keep up the good work! |
@develar is there a description of how NSIS differential updates work? Do you think it might be possible and worthwhile to make NSIS differential updates an option officially supported in the AppImage standard? (Not promising anything, just trying to understand the pros and cons.) Especially, how do NSIS differential updates know the URL to "update themselves" from? |
And, does the application author have to specifically produce delta files from each version to each version or does it work similar to zsync where you don't have to do this? |
Note: Bintray is not described in this overview, because not suitable for a lot of users due to unacceptable pricing and so, not fully supported and not recommended by electron-builder anymore.
In short — NSIS differential update equals to zsync (again, currently, content defined chunking is not implemented, but will be — "depends on experiment results (how good is our differential updating compared to zsync"). So, as you can see, the only advantage of using zsync for us — content defined chunking. But in any case it should be implemented for NSIS, so it is not considered as "reinvent the wheel" :) Also, and it is also important, our chunker understands the data. Block map computed per application file (7z format supported for now, in the future we can do the same for squashfs image). It is why initially NSIS chunked was implemented using static slicing :) |
@develar Quick question: will this work for other distribution formats as well, like Debian packages? |
@MaKleSoft AppX, Snap, Debian, rpm, pacman and so on are out of scope because you should use OS to update them. That's why AppImage is a default target — because it works on all Linux distro and updatable on all Linux too. |
@develar Got it. Thanks for the quick response! |
@develar are you going to write the entire updater code in JS to make it portable, or are you building something subprocess based (e.g., calling NSIS processes)? I'm not quite sure what you're building. |
@TheAssassin electron-updater differential updater for Windows Web Installer is already implemented and works in production.
The same will be implemented (if zsync will be not better (delta)) in case of AppImage (step 1 is missed, step 3 replaced to "integrate into system (new icons and so)"). |
Our CDC (content defined chunking) works ideally. In general, delta update size equals to For AppImage we don't use And in any case problem is that decompression of xz is slow and it leads to slow startup of app. Not often noticeable. And definitely, we don't want to compromise AppImage. You still can set in the So, by default gzip compression is used. It is why Windows installer has size 34 MB, but Linux AppImage 52 MB. But because of that delta update size is very small — minimal ~100 KB.
Our one-click method |
So, would you say we shuold look into NSIS instead of zsync for AppImage in general? |
electron-builder 19.37.0 Both versions are
|
“File file” in the log not a typo :) Just because the whole AppImage added to block map as file named ‚file‘ :) |
AutoUpdater now works great with AppImage except for one minor thing - the downloaded AppImage needs to be manually made executable (using |
It is already executable. 247c18a#diff-0bb16ebe6bbc7bee3f53626ef72f6660R114 I have checked updater manualyl, not only using integration tests. Please provide steps to reproduce and file new issue. |
Hmmm... that's interesting. Not sure why but I got it working using the
|
Keep in mind — some breaking change may be done #2216 |
I'm not sure if this is the place for asking this. I've made a progress bar which is working great on Windows with NSIS, but the event Is it supposed to be working or this is the expected behavior? Thanks! |
hi ! I have the same problem. Have you solved it? |
1 similar comment
hi ! I have the same problem. Have you solved it? |
Electron-simple-updater supports appimage Linux Auto-updates, could this be ported to electron-builder?
The text was updated successfully, but these errors were encountered: