hsjobeki
78c0ad24d9
Merge pull request 'Refactor(api/update_machine): rename to set_machine; use name, flake' ( #3899 ) from api-narrowing into main
...
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3899
2025-06-09 11:55:28 +00:00
Johannes Kirschbauer
2685db33d7
Refactor(cli/list_machines): rename to list_full_machines
...
This makes it clear that this should be used with care
It is potentially more expensive to create the full object, therefore it should be discouraged by its longer name
This listing is implemented based on the basic listing, where each item is turned into the bigger machine class
2025-06-09 13:40:57 +02:00
Johannes Kirschbauer
57e71e6c66
Refactor(api/list_machines): rename from list_inv_machines
2025-06-09 13:33:25 +02:00
Johannes Kirschbauer
7c4b836963
refactor(clan_lib): move show_clan_meta to clan_lib
2025-06-09 13:33:25 +02:00
Johannes Kirschbauer
ad948ec097
refactor(clan_lib): move update to clan_lib.clan
2025-06-09 13:33:25 +02:00
Johannes Kirschbauer
7f478bffe2
Refactor(api/update_machine): rename to set_machine; use name, flake
2025-06-09 13:33:19 +02:00
lassulus
8ce860f0d3
Revert "clan-cli: Use Remote class in DeployInfo, add tests for qrcode parser and json parser"
...
This reverts commit b1ef5f00bf .
2025-06-09 11:28:15 +02:00
hsjobeki
4faec2c4d2
Merge pull request 'Chore(api): narrow down get_machine' ( #3863 ) from api-narrowing into main
...
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3863
2025-06-09 08:59:36 +00:00
Qubasa
b1ef5f00bf
clan-cli: Use Remote class in DeployInfo, add tests for qrcode parser and json parser
2025-06-07 00:51:24 +02:00
lassulus
d3d5cd70cb
Merge pull request 'fix select escaping' ( #3857 ) from lassulus/test into main
...
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3857
2025-06-06 10:58:14 +00:00
lassulus
4d07e90930
select: fix error message showing nonsense
2025-06-06 10:12:15 +02:00
lassulus
e96099d588
select: fix non escaped '
2025-06-06 10:12:15 +02:00
Qubasa
4fa73e4b92
clan_lib: Fix quoting issues
2025-06-05 17:24:36 +02:00
Johannes Kirschbauer
730ab8a25e
Chore(specific_machine_dir): use protocol to avoid direct dependency on machine class
2025-06-04 20:51:27 +02:00
Johannes Kirschbauer
ea1c1a5185
Chore(api): narrow down get_machine
...
Dont require the user to pass the machine into the same getter function
The workflow contradicts itself here
2025-06-04 20:38:45 +02:00
hsjobeki
6679a64dea
Merge pull request 'feat(inventory/instances): add option for extraModules to roles' ( #3830 ) from flake-models into main
...
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3830
2025-06-03 18:58:13 +00:00
Johannes Kirschbauer
ac0477e710
Fix(inventory/extraModules): use more narrow type for better persistence
2025-06-03 18:57:34 +02:00
Johannes Kirschbauer
724e307cac
Chore: update clan nix_models
2025-06-03 18:18:12 +02:00
Johannes Kirschbauer
77c2fc7ba1
chore: delete duplicate inventory models
2025-06-03 17:52:07 +02:00
Jörg Thalheim
97209c53e4
fix buildhost re-using control socket for updates
...
this is actually a serious issue because it also would result doing ssh
to the wrong host: https://git.clan.lol/clan/clan-core/issues/3822
2025-06-03 14:01:49 +02:00
Michael Hoang
06d0612b5f
cli: allow using commands from local flakerefs for debugging
2025-06-03 14:07:45 +10:00
Qubasa
2bbf97199f
clan-cli: Fix test_create::test_clan_create_api
2025-06-02 15:39:50 +02:00
Qubasa
ae41bfad8c
inventory: Add buildHost argument
2025-06-02 14:52:13 +02:00
hsjobeki
526a992101
Merge pull request 'Tests(inventoryStore): add tests for intersecting nix/json lists' ( #3783 ) from flake-models into main
...
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3783
2025-05-30 08:35:13 +00:00
Johannes Kirschbauer
e4b95b5465
Test(InventoryPersistence): improve error message
2025-05-30 10:23:57 +02:00
Jörg Thalheim
1688972bce
move test_ssh_remote to remote_test
2025-05-28 20:13:48 +02:00
Jörg Thalheim
ddab4b5b94
re-store controllmaster in various places where it got removed.
2025-05-28 16:21:30 +02:00
Jörg Thalheim
f3cdcef523
no longer require controlmaster for interactive ssh
...
we only run one ssh command, so control master is not needed
2025-05-28 16:21:30 +02:00
Jörg Thalheim
7b8b23b39b
ssh/remote: Improve error message if _control_path_dir is not set
2025-05-28 16:21:30 +02:00
Jörg Thalheim
cedc5113ea
add sudo_askpass_proxy
2025-05-28 16:21:30 +02:00
Jörg Thalheim
6839b9616d
ssh/remote: make sure we also cleanup clan-ssh in the error case
2025-05-28 16:21:30 +02:00
Jörg Thalheim
37840dd203
remove unused method
2025-05-28 16:21:30 +02:00
Johannes Kirschbauer
976c4d52cb
Tests(inventoryStore): add tests for intersecting nix/json lists
2025-05-28 15:39:52 +02:00
Johannes Kirschbauer
07a574cbb0
Tests(inventoryStore): add fixture, make extensible
2025-05-28 15:06:17 +02:00
Johannes Kirschbauer
4b5880d1cb
Fix(machines/create): use 'InventorySnapshot' as init argument
...
Inventory as a model is generally not json serializable
InventorySnapshot is the return value of InventoryStore.{read, write}
And should be used in API calls, because the other fields might not be compatible in general
2025-05-28 14:09:45 +02:00
Johannes Kirschbauer
104343a334
feat(InventoryStore): return a restricted view of the inventory
2025-05-28 14:04:34 +02:00
Johannes Kirschbauer
bac3e6c2b2
Chore: update clan nix_models
2025-05-28 14:03:23 +02:00
Johannes Kirschbauer
d482e22610
chore(nix_models): migrate import to use exported clan models
2025-05-28 14:03:22 +02:00
Johannes Kirschbauer
1ef2e13c85
feat(nix_models): replace inventory model by holistic clan model
2025-05-28 14:02:43 +02:00
Johannes Kirschbauer
db31b91401
Fix(inventoryStore): use 'nix_eval' wrapper to set the store correct
2025-05-28 11:34:16 +02:00
Johannes Kirschbauer
84622222d8
Fix(tests): fix failing pytests
2025-05-28 11:01:54 +02:00
Johannes Kirschbauer
4c6063c75e
Tests(inventoryStore): fixup tests to run in ci
2025-05-28 10:42:47 +02:00
Johannes Kirschbauer
a49466e1a9
Feat(inventoryStore): add possibility to turn off output filtering
2025-05-28 10:42:47 +02:00
Johannes Kirschbauer
dd9ea44770
refactor(persist/utils): rename apply_patch to 'set_value_by_path'
2025-05-28 10:16:48 +02:00
Johannes Kirschbauer
f591ac0c32
Feat(inventoryStore): add 'invalidate_cache' to the Flake protocol
2025-05-27 17:56:35 +02:00
Johannes Kirschbauer
e6d1f71907
Feat(inventory): remove legacy action functions
...
Inventory should only and always be accessed through the inventory store.
Manually reading and writing to the json file is highly insecure
2025-05-27 17:20:04 +02:00
Johannes Kirschbauer
c32d196428
Fix: configure deferred setting module path correctly
2025-05-27 16:31:54 +02:00
Johannes Kirschbauer
90d9dbb242
Refactor(lib/inventory): move machine actions into clan_lib/machines/actions.py
2025-05-26 17:51:12 +02:00
hsjobeki
91a6f814d6
Merge pull request 'Feat(persist): add support for deferredModule read/write' ( #3752 ) from deferredModule-serde into main
...
Reviewed-on: https://git.clan.lol/clan/clan-core/pulls/3752
2025-05-26 14:18:53 +00:00
Qubasa
b85aead33c
clan-cli: Fix too long path for socket issue #3756
2025-05-25 22:16:51 +02:00