Resin’s delta server supports Balena deltas as version 3 deltas. This commit adds support for triggering delta generation for Balena deltas, and applying them locally to the device via a simple pull.
The delta version to use when updating has been abstracted away as an env var that is user-defined. The default value is still instructing use of rsync deltas (v2).
Change-Type: minor
The supervisor will now check that a source of an application matches
the current source, and only start it if so.
Change-type: patch
Closes: #658
Signed-off-by: Cameron Diver <cameron@resin.io>
This field will represent the apiEndpoint that the application came
from, (or an empty string for local apps). This means that when
configuring an application to work on a different environment, as long
as the endpoint is different, the supervisor can know not to start the
old application.
Change-type: minor
Connects-to: #658
Signed-off-by: Cameron Diver <cameron@resin.io>
This api endpoint is the endpoint which the intial config was reported.
Also changed the code to detect if the api endpoint has changed, and
therefore whether we need to re-report the initial config, to avoid
losing hardware specific information.
Change-type: minor
Closes: #649
Signed-off-by: Cameron Diver <cameron@resin.io>
We add a bunch of additional unit tests, and also a coverage report using istanbul.
The tests are not meant to cover everything, but they're a first attempt at having *some* unit testing
on the supervisor. There's much to improve but hopefully it helps catch obvious errors.
Change-Type: patch
Signed-off-by: Pablo Carranza Velez <pablo@resin.io>
This is to combat when a working directory is in the compose file for a
service with a trailing slash. Docker will strip this slash and that
means service comparisons will fail going forward - even if they are the
same.
Change-type: patch
Closes: #635
Signed-off-by: Cameron Diver <cameron@resin.io>
Add webpack config and dependencies to have typescript built, and also
convert src/lib/validation.coffee to typescript.
In this conversion I also added a lot of debugging which should help the
upcoming local mode development.
Change-type: minor
Signed-off-by: Cameron Diver <cameron@resin.io>