Felipe Lalanne
ede27b63ce
Fix engine deadlock on network+service change
...
This fixes a regression on the supervisor state engine computation
(added on v16.2.0) when
the target state removes a network at the same time that a service
referencing that network is changed. Example going from
```
services:
one:
image: alpine: 3.18
networks: ['balena']
networks:
balena:
```
to
```
services:
one:
image: alpine: latest
```
Would never reach the target state as killing the service in order to
remove the network is prioritized, but one of the invariants in the target state calculation is
to not kill any services until all images have been downloaded. These
two instructions were in contradiction leading to a deadlock.
The fix involves only adding removal steps for services depending on a
changing network or volume if the service container is not being removed
already.
Change-type: patch
2024-06-24 18:12:12 -04:00
Felipe Lalanne
5d93f358aa
Create replicating test
...
This adds a test to check the case where a service image changes along
with networks being removed.
2024-06-24 15:54:19 -04:00
flowzone-app[bot]
1c3e24ec29
v16.3.16
2024-06-17 01:56:14 +00:00
balena-renovate[bot]
1fe754ca34
Merge pull request #2346 from balena-os/renovate/balena-io-deploy-to-balena-action-2.0.x
...
Update balena-io/deploy-to-balena-action action to v2.0.72
2024-06-17 01:55:12 +00:00
Self-hosted Renovate Bot
170733422a
Update balena-io/deploy-to-balena-action action to v2.0.72
...
Update balena-io/deploy-to-balena-action from 2.0.71 to 2.0.72
Change-type: patch
2024-06-17 01:36:59 +00:00
flowzone-app[bot]
20fa8fd0c3
v16.3.15
2024-06-10 01:57:08 +00:00
balena-renovate[bot]
17e0e08b97
Merge pull request #2344 from balena-os/renovate/balena-io-deploy-to-balena-action-2.0.x
...
Update balena-io/deploy-to-balena-action action to v2.0.71
2024-06-10 01:56:08 +00:00
Self-hosted Renovate Bot
552f77cef5
Update balena-io/deploy-to-balena-action action to v2.0.71
...
Update balena-io/deploy-to-balena-action from 2.0.70 to 2.0.71
Change-type: patch
2024-06-10 01:36:51 +00:00
flowzone-app[bot]
0a3ce26116
v16.3.14
2024-06-09 13:30:01 +00:00
balena-renovate[bot]
a22c2049d6
Merge pull request #2343 from balena-os/renovate/got
...
Update got to v14.4.1
2024-06-09 13:29:01 +00:00
Self-hosted Renovate Bot
11628cda16
Update got to v14.4.1
...
Update got from 14.3.0 to 14.4.1
Change-type: patch
2024-06-09 13:09:09 +00:00
flowzone-app[bot]
2b8227dd0a
v16.3.13
2024-06-05 20:43:15 +00:00
flowzone-app[bot]
89baf8dec3
Merge pull request #2340 from balena-os/refactor-device-state
...
Refactor device state module
2024-06-05 20:42:13 +00:00
Felipe Lalanne
45d1f1f964
Split target state set/get into separate module
...
This removes the circular dependency between device state index and
preloading and cleans up the device state module code
Change-type: patch
2024-06-03 11:40:47 -04:00
Felipe Lalanne
fedeb518e5
Move device-state.ts into the device-state/index.ts
...
Change-type: patch
2024-06-03 11:40:47 -04:00
Felipe Lalanne
9497eed380
Move device-state/target state to api-binder/poll
...
This goes in the direction of grouping modules by responsibility. The
api-binder module is the middleware between the device and the backend,
thus the target state polling code makes more sense there.
Change-type: patch
2024-06-03 11:40:46 -04:00
flowzone-app[bot]
af1ef086fe
v16.3.12
2024-06-03 01:56:03 +00:00
balena-renovate[bot]
77db5c89cf
Merge pull request #2341 from balena-os/renovate/balena-io-deploy-to-balena-action-2.0.x
...
Update balena-io/deploy-to-balena-action action to v2.0.70
2024-06-03 01:55:11 +00:00
Self-hosted Renovate Bot
d7a325b80a
Update balena-io/deploy-to-balena-action action to v2.0.70
...
Update balena-io/deploy-to-balena-action from 2.0.69 to 2.0.70
Change-type: patch
2024-06-03 01:36:04 +00:00
flowzone-app[bot]
1a303c4bb4
v16.3.11
2024-05-27 20:04:29 +00:00
flowzone-app[bot]
1264012fad
Merge pull request #2334 from balena-os/circular-dependencies
...
Refactor code to reduce circular dependencies between modules
2024-05-27 20:03:42 +00:00
Felipe Lalanne
027c2575b1
Move OS variant retrieval to config module
...
This also deprecates the `getOSVariant` function of the `os-release`
module, as the OS variant are no longer defined in `/etc/os-release`.
Change-type: patch
2024-05-27 14:36:03 -04:00
Felipe Lalanne
59689b2789
Do not export balenaApi on api-binder
...
Instead, add `getBalenaApi` function to api-helper so other modules can
access a balena API instance.
Further reduces circular dependencies to 5
Change-type: patch
2024-05-27 14:36:03 -04:00
Felipe Lalanne
ac2db38742
Move api-keys module to src/lib
...
This removes circular dependencies between the device-api module and
the compose module, reducing total circular dependencies to 15
Change-type: patch
2024-05-27 14:36:03 -04:00
Felipe Lalanne
48f75e61b8
Do not re-export ContractObject on lib/contracts
...
Further reduce circular dependencies to 10
Change-type: patch
2024-05-27 14:36:03 -04:00
Felipe Lalanne
bef5e78440
Move Compose(Network|Volume)Config to top level types
...
This reduces dependencies from 80 to 47
Change-type: patch
2024-05-27 14:36:03 -04:00
Felipe Lalanne
234e0de075
Move composition types to compose/types
...
This reduces circular dependencies from 250 to 80 by ensuring that
modules that only require types do not import the full module with all
its dependencies.
Change-type: patch
2024-05-27 14:36:03 -04:00
Felipe Lalanne
94de4006a0
Split compose types into interface and implementation
...
This splits `App`, `Network`, `Service` and `Volume` which used to be
defined as classes into an interface and a class implementation that is
not exported. This will allow to work with just the types in some cases
and prevent circular dependencies when importing.
Change-type: patch
2024-05-27 14:36:03 -04:00
flowzone-app[bot]
435a363716
v16.3.10
2024-05-27 02:41:53 +00:00
balena-renovate[bot]
13f1ce8863
Merge pull request #2337 from balena-os/renovate/got
...
Update got to v14.3.0
2024-05-27 02:40:46 +00:00
Self-hosted Renovate Bot
4764bca2c4
Update got to v14.3.0
...
Update got from 14.2.1 to 14.3.0
Change-type: patch
2024-05-27 02:21:21 +00:00
flowzone-app[bot]
5de8f40ddf
v16.3.9
2024-05-27 01:59:28 +00:00
balena-renovate[bot]
a2ceb6e663
Merge pull request #2339 from balena-os/renovate/balena-io-deploy-to-balena-action-2.0.x
...
Update balena-io/deploy-to-balena-action action to v2.0.69
2024-05-27 01:58:32 +00:00
Self-hosted Renovate Bot
9cdb363e4c
Update balena-io/deploy-to-balena-action action to v2.0.69
...
Update balena-io/deploy-to-balena-action from 2.0.68 to 2.0.69
Change-type: patch
2024-05-27 01:35:18 +00:00
flowzone-app[bot]
1ece3376f0
v16.3.8
2024-05-24 14:29:21 +00:00
balena-renovate[bot]
9a776e0e1b
Merge pull request #2338 from balena-os/renovate/balena-io-deploy-to-balena-action-2.0.x
...
Update balena-io/deploy-to-balena-action action to v2.0.68
2024-05-24 14:28:34 +00:00
Self-hosted Renovate Bot
8a7972c783
Update balena-io/deploy-to-balena-action action to v2.0.68
...
Update balena-io/deploy-to-balena-action from 2.0.67 to 2.0.68
Change-type: patch
2024-05-24 14:09:21 +00:00
flowzone-app[bot]
35a4b676d4
v16.3.7
2024-05-24 13:45:26 +00:00
Page-
68fe016526
Merge pull request #2335 from balena-os/renovate/major-sinon
...
Update sinon to v18
2024-05-24 14:44:30 +01:00
Self-hosted Renovate Bot
6b47c3572d
Update sinon to v18
...
Update sinon from 17.0.1 to 18.0.0
Change-type: patch
2024-05-20 02:21:03 +00:00
flowzone-app[bot]
127d4060e7
v16.3.6
2024-05-20 01:54:08 +00:00
balena-renovate[bot]
be45fcb623
Merge pull request #2336 from balena-os/renovate/balena-io-deploy-to-balena-action-2.0.x
...
Update balena-io/deploy-to-balena-action action to v2.0.67
2024-05-20 01:53:19 +00:00
Self-hosted Renovate Bot
21f72b0ce9
Update balena-io/deploy-to-balena-action action to v2.0.67
...
Update balena-io/deploy-to-balena-action from 2.0.66 to 2.0.67
Change-type: patch
2024-05-20 01:34:21 +00:00
flowzone-app[bot]
59e50ffabd
v16.3.5
2024-05-13 01:53:54 +00:00
balena-renovate[bot]
47688f2263
Merge pull request #2333 from balena-os/renovate/balena-io-deploy-to-balena-action-2.0.x
...
Update balena-io/deploy-to-balena-action action to v2.0.66
2024-05-13 01:53:09 +00:00
Self-hosted Renovate Bot
0786f6d95b
Update balena-io/deploy-to-balena-action action to v2.0.66
...
Update balena-io/deploy-to-balena-action from 2.0.65 to 2.0.66
Change-type: patch
2024-05-13 01:34:36 +00:00
flowzone-app[bot]
83f6009aca
v16.3.4
2024-05-12 16:29:22 +00:00
balena-renovate[bot]
2941840700
Merge pull request #2332 from balena-os/renovate/patch-semver
...
Update semver to v7.6.2
2024-05-12 16:28:25 +00:00
Self-hosted Renovate Bot
da5fdc5d78
Update semver to v7.6.2
...
Update semver from 7.6.1 to 7.6.2
Change-type: patch
2024-05-12 16:09:16 +00:00
flowzone-app[bot]
e95f32588a
v16.3.3
2024-05-10 16:29:36 +00:00