Commit Graph

3329 Commits

Author SHA1 Message Date
brianmcgee
85c20ccb49 Merge pull request 'feat(ui): introduces storybook' (#3767) from feat/storybook into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3767
2025-05-26 13:55:46 +00:00
a-kenji
c0d7e85446 pkgs/generate-test-vars: Fix erroneous module import
The machines module lives in the `clan_lib` library.
2025-05-26 15:43:41 +02:00
a-kenji
cca0c2aff8 pkgs/generate-test-vars: Add basic module test
Add a basic module test that can catch breaking changes in module
usage.
2025-05-26 15:41:48 +02:00
Brian McGee
717f78b29c feat(ui): introduces storybook
- adds the necessary dependencies and configuration for Storybook.
- refactors the `Button` component and adds some stories for it.
2025-05-26 12:56:51 +01:00
brianmcgee
784e90096b Merge pull request 'feat(ui): add a clan context provider' (#3744) from feat/clan-uri-context into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3744
2025-05-26 09:26:07 +00:00
Qubasa
b85aead33c clan-cli: Fix too long path for socket issue #3756 2025-05-25 22:16:51 +02:00
Johannes Kirschbauer
fe933d8eb7 Fix(machines/create): check if machine is already created 2025-05-23 22:31:06 +02:00
Johannes Kirschbauer
c8588eddb6 Fix(machines/create): always add 'deploy.targetHost'
Rationale: not passing the value, is equivalent to deleting a value from the inventory store
See: 'delete_by_path'
deploy.targetHost has a default of null (None)
2025-05-23 22:07:09 +02:00
Johannes Kirschbauer
a7f4927e0c test(persist/inventory): add test for adding deferredModule
This feature will allow us to read/write to 'settings' of service
'instances' which are of type deferredModule.
Usually a deferredModule needs to be evaulated, but because we use our
own type, which forces some constraints, we can safely perform read and
write
2025-05-23 21:49:16 +02:00
Johannes Kirschbauer
9cea8e8901 fix(persist/delete): delete explizitly 2025-05-23 21:47:12 +02:00
Johannes Kirschbauer
0bf183b73b fix(tests): use inventory store to interact with the inventory 2025-05-23 21:46:35 +02:00
Johannes Kirschbauer
4d9202551f feat(persist/inventory): add transformation and filtering to support deferredModules 2025-05-23 21:45:52 +02:00
Johannes Kirschbauer
1b11ecf37a fixes(persist/util): fix some expected error messages in tests 2025-05-23 21:43:49 +02:00
Johannes Kirschbauer
38b2f0ca0f test(persist/util): add test for adding empty submodules 2025-05-23 21:43:09 +02:00
Johannes Kirschbauer
040e12c3e9 refactor(persist/util): improve calc_patches 2025-05-23 21:42:35 +02:00
Johannes Kirschbauer
9572f36175 feat(persist/util): init parent_is_dict
Check if a parent value is of type dict
This utility is helpfull for cross checking of flattened dicts
2025-05-23 21:41:34 +02:00
Johannes Kirschbauer
598902a766 chore(inventory): find_deleted_paths rename variables 2025-05-23 21:40:02 +02:00
Johannes Kirschbauer
29f1c6ee0a fix(inventory/store): keep empty dicts as leafs 2025-05-23 21:39:23 +02:00
Johannes Kirschbauer
3f82ceddb3 test(inventory/store): clean up simple test 2025-05-23 21:38:16 +02:00
Johannes Kirschbauer
6cd2c1ce1a feat(inventory/store): init path_match utility 2025-05-23 21:36:14 +02:00
lassulus
c7384a60c2 clan_lib flake_test: fix on darwin 2025-05-23 12:29:34 +02:00
Qubasa
8b1968cca6 clan-cli: Move Machine object to clan_lib 2025-05-22 19:11:19 +02:00
Brian McGee
4bba02afd4 feat(ui): add a clan context provider
- introduces a new consolidated store with `localStorage` support
- introduces a top-level `ClanProvider` providing access to `activeClanURI` and `clanURIs`
- redirects to `/welcome` if `activeClanURI` is `undefined`
- consolidates clan meta querying
- centralises the logic for removal of clan uri's which no longer exist
- fixed some miscellaneous missing `await` calls
2025-05-22 13:24:27 +00:00
Qubasa
d42dcb0e2a clan-cli: Fix ctrl+c cancelling tasks 2025-05-22 15:01:58 +02:00
Qubasa
e14f30bdc0 clan-cli: Rename Host -> Remote move to clan_lib and mark as frozen 2025-05-22 14:08:27 +02:00
Mic92
91994445ff Merge pull request 'fix build_host not beeing applied' (#3740) from fix-build-host into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3740
2025-05-22 11:25:20 +00:00
Brian McGee
8c5a30ff28 fix(ui): hot-reload of clan-cli 2025-05-22 11:47:35 +01:00
Jörg Thalheim
e275bb20bc fix build_host not beeing applied 2025-05-22 00:22:04 +02:00
lassulus
c64895fdff clan-cli: split clan into cli and lib 2025-05-21 20:28:41 +02:00
Johannes Kirschbauer
e2520f6aa8 Test(InventoryPersistence): add persist integration tests 2025-05-21 17:55:43 +02:00
Johannes Kirschbauer
0f7cc56776 Feat(inventoryStore): add FlakeInterface protocol 2025-05-21 16:44:28 +02:00
Michael Hoang
508bb14809 docs: misc clean up 2025-05-22 00:01:01 +10:00
kenji
dd85f9b557 Merge pull request 'pkgs/clan: Clean select symlink up' (#3734) from kenji/clan-core:ke-fix-clan-cli into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3734
Reviewed-by: lassulus <clanlol@lassul.us>
2025-05-21 13:08:21 +00:00
a-kenji
3662438f54 pkgs/clan: Clean select symlink up
If the symlink is not cleaned up this will break builds of the clan cli
from flakes with path references.
2025-05-21 14:18:26 +02:00
lassulus
cb0d7ae36a Merge pull request 'clan-cli: split backups into cli and lib' (#3733) from clan_lib_backups into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3733
2025-05-21 12:16:02 +00:00
DavHau
d833b62614 GUI: add credentials page (vars)
add it to machine details
2025-05-21 11:47:04 +00:00
lassulus
44e3df3ebf clan-cli: split backups into cli and lib 2025-05-21 13:46:35 +02:00
hsjobeki
70db1aae10 Merge pull request 'Fix: don't try to persist 'inventory.instances'' (#3731) from hsjobeki/clan-core:fix-2 into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3731
2025-05-21 10:36:29 +00:00
lassulus
4e1e35f88e Merge pull request 'clan-cli: clan_cli.inventory -> clan_lib.inventory' (#3730) from clan_lib_inv into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3730
2025-05-21 10:33:08 +00:00
lassulus
cb84722c11 clan-cli: clan_cli.bwrap -> clan_lib.bwrap 2025-05-21 12:06:38 +02:00
lassulus
2de3dcef15 clan-cli: clan_cli.inventory -> clan_lib.inventory 2025-05-21 12:06:38 +02:00
Johannes Kirschbauer
069d6e5569 Fix: don't try to persist 'inventory.instances' 2025-05-21 11:42:29 +02:00
hsjobeki
952ed43de0 Merge pull request 'Update UI to Node 22 and update dependencies' (#3729) from feat/update-ui-dependencies into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3729
2025-05-21 09:03:27 +00:00
hsjobeki
56a00e0afd Merge pull request 'Refactor(clan_lib): move serde tests next to serde module' (#3728) from hsjobeki/clan-core:chores-1 into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3728
2025-05-21 08:15:11 +00:00
Johannes Kirschbauer
6c1f8638f5 chore(clan_lib) add api.serde tests for typed_dict 2025-05-21 10:01:27 +02:00
Johannes Kirschbauer
ffc82928a7 docs: add doc-string to api serde utilities 2025-05-21 10:00:42 +02:00
Johannes Kirschbauer
70d06a189b Refactor(clan_lib): move serde tests next to serde module 2025-05-21 09:36:00 +02:00
hsjobeki
f470ebce1a Merge pull request 'Refactor(docs): consistent structure across references & fix broken cli links' (#3724) from hsjobeki/clan-core:docs-3 into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3724
2025-05-21 07:23:16 +00:00
Mic92
a22d3e3ff2 Merge pull request 'fix sudo in clan flash when restoring auto-updates' (#3717) from restore-automount into main
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3717
2025-05-20 16:49:39 +00:00
Johannes Kirschbauer
b7c6e8917b docs: replace remote url by local file links to allow for checking 2025-05-20 18:49:35 +02:00